public void op_GetResponse_HttpWebRequest_CookieContainer_whenNotFound()
        {
            var cookies = new CookieContainer();
            var request = new HttpRequest
            {
                Line = new HttpRequestLine("GET", "http://www.alan-dean.com/example")
            };

            using (var response = HttpExpectation.GetResponse(request, cookies))
            {
                Assert.Equal(HttpStatusCode.NotFound, response.StatusCode);
            }
        }
        public void op_GetResponse_HttpWebRequest_CookieContainer_whenOnlyLine()
        {
            var cookies = new CookieContainer();
            var request = new HttpRequest
            {
                Line = new HttpRequestLine("GET", "http://www.alan-dean.com/")
            };

            using (var response = HttpExpectation.GetResponse(request, cookies))
            {
                Assert.Equal(HttpStatusCode.SeeOther, response.StatusCode);
                Assert.Equal("http://www.alan-dean.com/about", response.Headers[HttpResponseHeader.Location]);
            }
        }
 public void op_GetResponse_HttpWebRequest_CookieContainerNull()
 {
     Assert.Throws <ArgumentNullException>(() => HttpExpectation.GetResponse(new HttpRequest(), null));
 }