예제 #1
0
 public void Should_build_response_with_status_code()
 {
     // given
     var response = new HttpResponse(404, "NOT FOUND");
     // when
     var textResponse = response.ToString();
     // then
     Check.That(textResponse).StartsWith("HTTP/1.1 404");
 }
예제 #2
0
        public void Should_build_response_with_status_code()
        {
            // given
            var response = new HttpResponse(404, "NOT FOUND");
            // when
            var textResponse = response.ToString();

            // then
            Check.That(textResponse).StartsWith("HTTP/1.1 404");
        }
예제 #3
0
 public void Should_build_response_with_headers()
 {
     // given
     var response = new HttpResponse(404, "NOT FOUND");
     response.AddHeader("DummyHeader", "DummyValue");
     // when
     var textResponse = response.ToString();
     // then
     Check.That(textResponse).Contains("DummyHeader: DummyValue");
 }
예제 #4
0
        public void Should_build_response_with_headers()
        {
            // given
            var response = new HttpResponse(404, "NOT FOUND");

            response.AddHeader("DummyHeader", "DummyValue");
            // when
            var textResponse = response.ToString();

            // then
            Check.That(textResponse).Contains("DummyHeader: DummyValue");
        }