private void TestDeepEquals(Activity objectA, Activity objectB, bool expect, bool expectDeep) { objectA.At = objectB.At; Assert.AreEqual(expectDeep, objectA.DeepEquals(objectB)); Assert.AreEqual(expectDeep, objectB.DeepEquals(objectA)); Assert.AreEqual(expect, objectA.Equals(objectB)); Assert.AreEqual(expect, objectB.Equals(objectA)); }
public void TestActivityDeserialize_02() { DateTime date = new DateTime(2002, 1, 1); Activity activity = new Activity(date, "action 1"); string str = XmlHelper.Instance.ToXmlString<Activity>(activity); Activity des = XmlHelper.Instance.FromXmlString<Activity>(str); Assert.IsTrue(activity.DeepEquals(des)); }