示例#1
0
 public void TestWithSparseValues()
 {
     SqlProcScaffoldTest.Procs.Proc.DefaultConnection = _sqlConnection;
     using (var dataReader = new SqlProcScaffoldTest.Procs.dbo.sp_sproc_wrapper_test(
                1,
                varcharNoDefault: "varcharNoDefault")
                             .ExecuteDataReader())
     {
         dataReader.Read();
         Assert.AreEqual(1, dataReader.GetInt32(0));
     }
 }
示例#2
0
 public void TestWithNullValues()
 {
     SqlProcScaffoldTest.Procs.Proc.DefaultConnection = _sqlConnection;
     using (var dataReader = new SqlProcScaffoldTest.Procs.dbo.sp_sproc_wrapper_test(
                intNoDefault: 1,
                intNullDefault: null,
                intNumericDefault: null,
                varcharNoDefault: "varcharNoDefault",
                varcharNullDefault: null,
                varcharValueDefault: null)
                             .ExecuteDataReader())
     {
         dataReader.Read();
         Assert.AreEqual(1, dataReader.GetInt32(0));
     }
 }
示例#3
0
 public void TestWithExplicitConnection()
 {
     using (var dataReader = new SqlProcScaffoldTest.Procs.dbo.sp_sproc_wrapper_test(
                1,
                "varcharNoDefault",
                2,
                3,
                "varcharNullDefault",
                "varcharValueDefault")
                             .SetConnection(_sqlConnection)
                             .ExecuteDataReader())
     {
         dataReader.Read();
         Assert.AreEqual(1, dataReader.GetInt32(0));
     }
 }