public void EqualsTest() { IVideo vid = null; int id = 0; int idFather = 0; ObservableCollection<SmartNode> smartTree = null; SmartNode target = new SmartNode(vid, id, idFather, smartTree); object obj = null; bool expected = false; bool actual; actual = target.Equals(obj); Assert.AreEqual(expected, actual); }
public void EqualsTest1() { Video testvideo = new Video(true, "test/test.yuv"); IVideo vid = testvideo; int id = 5; int idFather = 4; ObservableCollection<SmartNode> smartTree = null; SmartNode target = new SmartNode(vid, id, idFather, smartTree); IVideo vid2 = testvideo; int id2 = 5; int idFather2 = 4; ObservableCollection<SmartNode> smartTree2 = null; SmartNode target2 = new SmartNode(vid, id2, idFather2, smartTree2); Assert.AreEqual(true, target.Equals(target2)); SmartNode target3 = new SmartNode(vid, 6, idFather2, smartTree2); Assert.AreNotEqual(target.Equals(target3), true); SmartNode target4 = new SmartNode(vid, id, 1337, smartTree2); Assert.AreNotEqual(target.Equals(target4), true); target2.smartTree.Add(target3); Assert.AreNotEqual(target.Equals(target2), true); }