Reacting to TestHost changes

This commit is contained in:
Kiran Challa 2015-09-16 12:17:29 -07:00
parent 7b433820b1
commit f3e537ddcb
2 changed files with 5 additions and 4 deletions

View File

@ -2,6 +2,7 @@
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System;
using System.Threading.Tasks;
using Microsoft.AspNet.Http;
using Microsoft.AspNet.Mvc.Actions;
using Microsoft.AspNet.Mvc.Routing;
@ -44,7 +45,7 @@ namespace Microsoft.AspNet.Mvc
}
[Fact]
public void RedirectToAction_Execute_ThrowsOnNullUrl()
public async Task RedirectToAction_Execute_ThrowsOnNullUrl()
{
// Arrange
var httpContext = new Mock<HttpContext>();
@ -60,7 +61,7 @@ namespace Microsoft.AspNet.Mvc
};
// Act & Assert
ExceptionAssert.ThrowsAsync<InvalidOperationException>(
await ExceptionAssert.ThrowsAsync<InvalidOperationException>(
async () =>
{
await result.ExecuteResultAsync(actionContext);

View File

@ -50,7 +50,7 @@ namespace Microsoft.AspNet.Mvc
}
[Fact]
public void RedirectToRoute_Execute_ThrowsOnNullUrl()
public async Task RedirectToRoute_Execute_ThrowsOnNullUrl()
{
// Arrange
var httpContext = new Mock<HttpContext>();
@ -66,7 +66,7 @@ namespace Microsoft.AspNet.Mvc
};
// Act & Assert
ExceptionAssert.ThrowsAsync<InvalidOperationException>(
await ExceptionAssert.ThrowsAsync<InvalidOperationException>(
async () =>
{
await result.ExecuteResultAsync(actionContext);