public void AsHttpResponseMessage() {
			var responseContent = new byte[10];
			(new Random()).NextBytes(responseContent);
			var responseStream = new MemoryStream(responseContent);
			var outgoingResponse = new OutgoingWebResponse();
			outgoingResponse.Headers.Add("X-SOME-HEADER", "value");
			outgoingResponse.Headers.Add("Content-Length", responseContent.Length.ToString(CultureInfo.InvariantCulture));
			outgoingResponse.ResponseStream = responseStream;

			var httpResponseMessage = outgoingResponse.AsHttpResponseMessage();
			Assert.That(httpResponseMessage, Is.Not.Null);
			Assert.That(httpResponseMessage.Headers.GetValues("X-SOME-HEADER").ToList(), Is.EqualTo(new[] { "value" }));
			Assert.That(
				httpResponseMessage.Content.Headers.GetValues("Content-Length").ToList(),
				Is.EqualTo(new[] { responseContent.Length.ToString(CultureInfo.InvariantCulture) }));
			var actualContent = new byte[responseContent.Length + 1]; // give the opportunity to provide a bit more data than we expect.
			var bytesRead = httpResponseMessage.Content.ReadAsStreamAsync().Result.Read(actualContent, 0, actualContent.Length);
			Assert.That(bytesRead, Is.EqualTo(responseContent.Length)); // verify that only the data we expected came back.
			var trimmedActualContent = new byte[bytesRead];
			Array.Copy(actualContent, trimmedActualContent, bytesRead);
			Assert.That(trimmedActualContent, Is.EqualTo(responseContent));
		}
		public void AsHttpResponseMessageNoContent() {
			var outgoingResponse = new OutgoingWebResponse();
			outgoingResponse.Headers.Add("X-SOME-HEADER", "value");

			var httpResponseMessage = outgoingResponse.AsHttpResponseMessage();
			Assert.That(httpResponseMessage, Is.Not.Null);
			Assert.That(httpResponseMessage.Headers.GetValues("X-SOME-HEADER").ToList(), Is.EqualTo(new[] { "value" }));
			Assert.That(httpResponseMessage.Content, Is.Null);
		}