Пример #1
0
        public MethodCheckMissingExceptionTests()
        {
            var fixture = new Fixture();

            methodName      = fixture.Create <string>();
            otherMethodName = fixture.Create <string>();

            paramName      = fixture.Create <string>();
            otherParamName = fixture.Create <string>();

            sut = new MethodCheckMissingException(methodName, paramName);
        }
Пример #2
0
        public void GetHashCode_WhenMethodNameDiffers_ReturnsDifferentHashCode()
        {
            var otherException = new MethodCheckMissingException(otherMethodName, paramName);

            sut.GetHashCode().Should().NotBe(otherException.GetHashCode());
        }
Пример #3
0
        public void Equals_GivenSameMethodNameAndParamName_ReturnsTrue()
        {
            var otherException = new MethodCheckMissingException(methodName, paramName);

            sut.Equals(otherException).Should().BeTrue();
        }
Пример #4
0
        public void Equals_GivenOtherParamName_ReturnsFalse()
        {
            var otherException = new MethodCheckMissingException(methodName, otherParamName);

            sut.Equals(otherException).Should().BeFalse();
        }
Пример #5
0
        public void GetHashCode_WhenSameMethodNameAndParamName_ReturnsSameHashCode()
        {
            var otherException = new MethodCheckMissingException(methodName, paramName);

            sut.GetHashCode().Should().Be(otherException.GetHashCode());
        }