Example #1
0
        public void SameNameAreEqual()
        {
            NamedElement element1 = new NamedElement('a');
            NamedElement element2 = new NamedElement('a');

            Assert.AreEqual(element1, element2);
            Assert.AreEqual(element1.GetHashCode(), element2.GetHashCode());
        }
Example #2
0
        public void DifferentNameAreNotEqual()
        {
            NamedElement element1 = new NamedElement('a');
            NamedElement element2 = new NamedElement('b');

            Assert.AreNotEqual(element1, element2);
            Assert.AreNotEqual(element1.GetHashCode(), element2.GetHashCode());
        }