Example #1
0
        private WebResponse CreateResponse()
        {
            var response = new MockHttpWebResponse(_requestUri, ContentType)
            {
                StatusCode        = ExpectStatusCode,
                StatusDescription = ExpectStatusDescription,
                Content           = Content
            };

            foreach (var key in ExpectHeaders.AllKeys)
            {
                response.MockHeaders.Add(key, ExpectHeaders[key].Value);
            }

            return(response);
        }
Example #2
0
        private WebResponse CreateResponse()
        {
            var response = new MockHttpWebResponse(_requestUri, ContentType)
            {
                StatusCode = ExpectStatusCode,
                StatusDescription = ExpectStatusDescription,
                Content = Content
            };

            foreach (var key in ExpectHeaders.AllKeys)
            {
                response.MockHeaders.Add(key, ExpectHeaders[key].Value);
            }

            return response;
        }