public void Creation()
 {
     Utilities.SQL.ParameterTypes.OrParameter TestObject = new Utilities.SQL.ParameterTypes.OrParameter(new EqualParameter<int>(1, "Left"), new EqualParameter<int>(2, "Right"));
     Assert.Equal("(Left=@Left OR Right=@Right)", TestObject.ToString());
     using (Utilities.SQL.SQLHelper Helper = new Utilities.SQL.SQLHelper("", "Data Source=localhost;Integrated Security=SSPI;Pooling=false", CommandType.Text))
     {
         Assert.DoesNotThrow<Exception>(() => TestObject.AddParameter(Helper));
     }
 }
Пример #2
0
 public void Creation()
 {
     Utilities.SQL.ParameterTypes.OrParameter TestObject = new Utilities.SQL.ParameterTypes.OrParameter(new EqualParameter <int>(1, "Left"), new EqualParameter <int>(2, "Right"));
     Assert.Equal("(Left=@Left OR Right=@Right)", TestObject.ToString());
     using (Utilities.SQL.SQLHelper Helper = new Utilities.SQL.SQLHelper("", CommandType.Text, "Data Source=localhost;Integrated Security=SSPI;Pooling=false"))
     {
         Assert.DoesNotThrow(() => Helper.AddParameter(TestObject));
     }
 }