示例#1
0
        public void GivenResponseWithIOException_WhenIsResponseTooLargeCalled_ThenPositiveResultExpected()
        {
            bool isResponseTooLarge = PageAdjuster.IsResponseTooLargeToRead(new Exception(string.Empty, new IOException()));

            isResponseTooLarge.Should().Be(true);
        }
示例#2
0
        public void GivenResponseWithWebException_WhenIsResponseTooLargeCalled_ThenPositiveResultExpected()
        {
            bool isResponseTooLarge = PageAdjuster.IsResponseTooLargeToRead(new Exception(string.Empty, new WebException(string.Empty, WebExceptionStatus.ConnectionClosed)));

            isResponseTooLarge.Should().Be(true);
        }
示例#3
0
        public void GivenResponseWithCommonException_WhenIsResponseTooLargeCalled_ThenNegativeResultExpected()
        {
            bool isResponseTooLarge = PageAdjuster.IsResponseTooLargeToRead(new Exception(null, new Exception()));

            isResponseTooLarge.Should().Be(false);
        }