コード例 #1
0
 public void IsCompliant_GivenANullableIntThatIsNull_ShouldReturnTrue()
 {
     var constraint = new NotNullConstraint ();
     int? nullableInt = null;
     var result = constraint.IsCompliant ( nullableInt, null );
     Assert.IsFalse ( result );
 }
コード例 #2
0
 public void IsCompliant_GivenNull_ShouldReturnFalse()
 {
     var constraint = new NotNullConstraint ();
     var result = constraint.IsCompliant ( null, null );
     Assert.IsFalse ( result );
 }
コード例 #3
0
 public void IsCompliant_GivenAnInt_ShouldReturnTrue()
 {
     var constraint = new NotNullConstraint ();
     var result = constraint.IsCompliant ( 1, null );
     Assert.IsTrue ( result );
 }