public void GetHashCodeShouldNotMatchWhenLeafsHaveDifferentValues() { // Arrange Event e1 = new Event.Leaf(0); Event e2 = new Event.Leaf(4); // Act int hash1 = e1.GetHashCode(); int hash2 = e2.GetHashCode(); e1.Equals(e2).Should().BeFalse(); }
public void GetHashCodeShouldMatchWhenLeafsHaveSameValues() { // Arrange Event e1 = new Event.Leaf(0); Event e2 = new Event.Leaf(0); // Act int hash1 = e1.GetHashCode(); int hash2 = e2.GetHashCode(); e1.Equals(e2).Should().BeTrue(); }