コード例 #1
0
        public void GetHashCodeOverride()
        {
            // Arrange
            var viewWrapperA = new ViewWrapper(frameworkElement);
            var viewWrapperB = new ViewWrapper(frameworkElement);

            // Act
            int hashCodeA = viewWrapperA.GetHashCode();
            int hashCodeB = viewWrapperB.GetHashCode();

            // Assert
            Assert.That(hashCodeA, Is.EqualTo(hashCodeB));
        }
コード例 #2
0
        public void GetHashCodeOverride()
        {
            // ARRANGE
            var viewWrapperA = new ViewWrapper(frameworkElement);
            var viewWrapperB = new ViewWrapper(frameworkElement);

            // ACT
            int hashCodeA = viewWrapperA.GetHashCode();
            int hashCodeB = viewWrapperB.GetHashCode();

            // ASSERT
            Assert.That(hashCodeA, Is.EqualTo(hashCodeB));
        }