Equals() 공개 메소드

Determines whether the specified System.Object, is equal to this instance.
public Equals ( object obj ) : bool
obj object The to compare with this instance.
리턴 bool
예제 #1
0
 public void TestEquality_Null()
 {
     var rs = new ResultState(TestStatus.Passed);
     Assert.AreNotEqual(null, rs);
     Assert.AreNotEqual(rs, null);
     Assert.False(rs.Equals(null));
 }
예제 #2
0
        public void TestEquality_WrongType()
        {
            var rs = new ResultState(TestStatus.Passed);
            var s = "123";

            Assert.AreNotEqual(rs, s);
            Assert.AreNotEqual(s, rs);
            Assert.False(rs.Equals(s));
        }