diff --git a/src/Microsoft.AspNet.TestHost/RequestFeature.cs b/src/Microsoft.AspNet.TestHost/RequestFeature.cs index a82bd177..7f639576 100644 --- a/src/Microsoft.AspNet.TestHost/RequestFeature.cs +++ b/src/Microsoft.AspNet.TestHost/RequestFeature.cs @@ -1,11 +1,10 @@ // Copyright (c) .NET Foundation. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. -using System; -using System.Collections.Generic; using System.IO; +using Microsoft.AspNet.Http; using Microsoft.AspNet.Http.Features; -using Microsoft.Extensions.Primitives; +using Microsoft.AspNet.Http.Internal; namespace Microsoft.AspNet.TestHost { @@ -14,7 +13,7 @@ namespace Microsoft.AspNet.TestHost public RequestFeature() { Body = Stream.Null; - Headers = new Dictionary(StringComparer.OrdinalIgnoreCase); + Headers = new HeaderDictionary(); Method = "GET"; Path = ""; PathBase = ""; @@ -25,7 +24,7 @@ namespace Microsoft.AspNet.TestHost public Stream Body { get; set; } - public IDictionary Headers { get; set; } + public IHeaderDictionary Headers { get; set; } public string Method { get; set; } diff --git a/src/Microsoft.AspNet.TestHost/ResponseFeature.cs b/src/Microsoft.AspNet.TestHost/ResponseFeature.cs index ec63ebe7..c0744d92 100644 --- a/src/Microsoft.AspNet.TestHost/ResponseFeature.cs +++ b/src/Microsoft.AspNet.TestHost/ResponseFeature.cs @@ -2,11 +2,11 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Collections.Generic; using System.IO; using System.Threading.Tasks; +using Microsoft.AspNet.Http; using Microsoft.AspNet.Http.Features; -using Microsoft.Extensions.Primitives; +using Microsoft.AspNet.Http.Internal; namespace Microsoft.AspNet.TestHost { @@ -17,7 +17,7 @@ namespace Microsoft.AspNet.TestHost public ResponseFeature() { - Headers = new Dictionary(StringComparer.OrdinalIgnoreCase); + Headers = new HeaderDictionary(); Body = new MemoryStream(); // 200 is the default status code all the way down to the host, so we set it @@ -29,7 +29,7 @@ namespace Microsoft.AspNet.TestHost public string ReasonPhrase { get; set; } - public IDictionary Headers { get; set; } + public IHeaderDictionary Headers { get; set; } public Stream Body { get; set; }