public void TestEqualsDifferentDate() { using (StringWriter sw = new StringWriter()) { SimpleDate d = new SimpleDate(1, 2, 2000); // Assert Assert.AreEqual(false, d.Equals(new SimpleDate(5, 2, 2012)), "SimpleDate should not equal to different date!"); } }
public void TestEqualsSameDate() { using (StringWriter sw = new StringWriter()) { SimpleDate d = new SimpleDate(1, 2, 2000); // Assert Assert.AreEqual(true, d.Equals(new SimpleDate(1, 2, 2000)), "SimpleDate should equal to same date!"); } }
public void TestEqualsString() { using (StringWriter sw = new StringWriter()) { SimpleDate d = new SimpleDate(1, 2, 2000); // Assert Assert.AreEqual(false, d.Equals("heh"), "SimpleDate should not equal to a string!"); } }