Fix https tests.
This commit is contained in:
parent
e7508af2d9
commit
0103307aac
|
|
@ -19,6 +19,7 @@ using System.IO;
|
||||||
using System.Net.Http;
|
using System.Net.Http;
|
||||||
using System.Security.Cryptography.X509Certificates;
|
using System.Security.Cryptography.X509Certificates;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Microsoft.AspNet.FeatureModel;
|
using Microsoft.AspNet.FeatureModel;
|
||||||
using Microsoft.AspNet.HttpFeature;
|
using Microsoft.AspNet.HttpFeature;
|
||||||
|
|
@ -87,7 +88,7 @@ namespace Microsoft.AspNet.Server.WebListener
|
||||||
var httpContext = new DefaultHttpContext((IFeatureCollection)env);
|
var httpContext = new DefaultHttpContext((IFeatureCollection)env);
|
||||||
var tls = httpContext.GetFeature<IHttpClientCertificateFeature>();
|
var tls = httpContext.GetFeature<IHttpClientCertificateFeature>();
|
||||||
Assert.NotNull(tls);
|
Assert.NotNull(tls);
|
||||||
await tls.GetClientCertificateAsync();
|
await tls.GetClientCertificateAsync(CancellationToken.None);
|
||||||
Assert.Null(tls.ClientCertificate);
|
Assert.Null(tls.ClientCertificate);
|
||||||
}))
|
}))
|
||||||
{
|
{
|
||||||
|
|
@ -104,7 +105,7 @@ namespace Microsoft.AspNet.Server.WebListener
|
||||||
var httpContext = new DefaultHttpContext((IFeatureCollection)env);
|
var httpContext = new DefaultHttpContext((IFeatureCollection)env);
|
||||||
var tls = httpContext.GetFeature<IHttpClientCertificateFeature>();
|
var tls = httpContext.GetFeature<IHttpClientCertificateFeature>();
|
||||||
Assert.NotNull(tls);
|
Assert.NotNull(tls);
|
||||||
await tls.GetClientCertificateAsync();
|
await tls.GetClientCertificateAsync(CancellationToken.None);
|
||||||
Assert.NotNull(tls.ClientCertificate);
|
Assert.NotNull(tls.ClientCertificate);
|
||||||
}))
|
}))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue