Пример #1
0
        public void Constructor_WithLocationUrl_ShouldReturnAResponseWithCorrectHeader()
        {
            var response = new RedirectResponse("http://google.com");

            Assert.That(response.Headers.Keys, Contains.Item("Location"));
            Assert.That(response.Headers["Location"], Is.EqualTo("http://google.com"));
        }
Пример #2
0
        public void Constructor_WithLocationUrl_ShouldReturnAResponseWithStatusCodeSeeOther()
        {
            var response = new RedirectResponse("http://google.com");

            Assert.That(response.StatusCode, Is.EqualTo(303));
        }