private static IEnumerable <TestCaseData> QueryProcedureCases() { yield return(new TestCaseData( TSql.QueryProcedure("text"), new SqlQueryCommand("text", new DbParameter[0], CommandType.StoredProcedure))); yield return(new TestCaseData( TSql.QueryProcedure("text", parameters: null), new SqlQueryCommand("text", new DbParameter[0], CommandType.StoredProcedure))); yield return(new TestCaseData( TSql.QueryProcedure("text", new { }), new SqlQueryCommand("text", new DbParameter[0], CommandType.StoredProcedure))); yield return(new TestCaseData( TSql.QueryProcedure("text", new { Parameter = new SqlParameterValueStub() }), new SqlQueryCommand("text", new[] { new SqlParameterValueStub().ToDbParameter("@Parameter") }, CommandType.StoredProcedure))); yield return(new TestCaseData( TSql.QueryProcedure("text", new { Parameter1 = new SqlParameterValueStub(), Parameter2 = new SqlParameterValueStub() }), new SqlQueryCommand("text", new[] { new SqlParameterValueStub().ToDbParameter("@Parameter1"), new SqlParameterValueStub().ToDbParameter("@Parameter2") }, CommandType.StoredProcedure))); }