Enabled tests to run in dotnet xunit runner

This commit is contained in:
Kiran Challa 2016-02-08 11:08:49 -08:00 committed by ryanbrandenburg
parent f743d75e59
commit cf6d7f9a56
4 changed files with 23 additions and 32 deletions

View File

@ -1,7 +0,0 @@
var VERSION='0.1'
var FULL_VERSION='0.1'
var AUTHORS='Microsoft Open Technologies, Inc.'
use-standard-lifecycle
k-standard-goals

View File

@ -314,7 +314,9 @@ namespace Microsoft.AspNetCore.Hosting
.UseStartup("Microsoft.AspNetCore.Hosting.Tests")
.Build();
Assert.Equal(Path.GetFullPath("bar"), host.Services.GetService<IApplicationEnvironment>().ApplicationBasePath);
var basePath = host.Services.GetRequiredService<IApplicationEnvironment>().ApplicationBasePath;
Assert.True(Path.IsPathRooted(basePath));
Assert.EndsWith(Path.DirectorySeparatorChar + "bar", basePath);
}
private IWebHostBuilder CreateWebHostBuilder()

View File

@ -4,7 +4,7 @@
"keyFile": "../../tools/Key.snk"
},
"content": [
"testroot/**/*"
"testroot/**/*"
],
"dependencies": {
"Microsoft.AspNetCore.Hosting": "1.0.0-*",
@ -16,24 +16,22 @@
"xunit": "2.1.0"
},
"frameworks": {
"dnxcore50": {
"dependencies": {
"dotnet-test-xunit": "1.0.0-dev-*"
},
"imports": "portable-net451+win8"
},
"dnx451": {
"frameworkAssemblies":
{
"System.Threading.Tasks": ""
},
"dependencies": {
"System.Threading.Tasks": "4.0.11-*",
"xunit.runner.console": "2.1.0"
}
},
"dnxcore50": {
"dependencies": {
"xunit.runner.aspnet": "2.0.0-aspnet-*"
},
"imports": "portable-net451+win8"
}
},
"testRunner": "xunit",
"commands": {
"test": "xunit.runner.aspnet"
}
}
"testRunner": "xunit"
}

View File

@ -4,31 +4,29 @@
"keyFile": "../../tools/Key.snk"
},
"dependencies": {
"Microsoft.AspNetCore.Testing": "1.0.0-*",
"Microsoft.AspNetCore.TestHost": "1.0.0-*",
"Microsoft.AspNetCore.Testing": "1.0.0-*",
"Microsoft.Extensions.DiagnosticAdapter": "1.0.0-*",
"Microsoft.NETCore.Platforms": "1.0.1-*",
"xunit": "2.1.0"
},
"frameworks": {
"dnxcore50": {
"dependencies": {
"dotnet-test-xunit": "1.0.0-dev-*"
},
"imports": "portable-net451+win8"
},
"dnx451": {
"frameworkAssemblies":
{
"System.Threading.Tasks": ""
},
"dependencies": {
"System.Threading.Tasks": "4.0.11-*",
"xunit.runner.console": "2.1.0"
}
},
"dnxcore50": {
"dependencies": {
"xunit.runner.aspnet": "2.0.0-aspnet-*"
},
"imports": "portable-net451+win8"
}
},
"testRunner": "xunit",
"commands": {
"test": "xunit.runner.aspnet"
}
}
"testRunner": "xunit"
}