Fixed NanoServer tests

This commit is contained in:
Kiran Challa 2017-03-08 15:00:41 -08:00
parent 7f4f4108db
commit 331c9a4e49
5 changed files with 15 additions and 4 deletions

View File

@ -55,7 +55,7 @@ namespace E2ETests
if (applicationType == ApplicationType.Standalone)
{
deploymentParameters.AdditionalPublishParameters = "/p:RuntimeIdentifier=" + RuntimeEnvironment.GetRuntimeIdentifier();
deploymentParameters.AdditionalPublishParameters = " -r " + RuntimeEnvironment.GetRuntimeIdentifier();
}
// Override the connection strings using environment based configuration

View File

@ -80,7 +80,7 @@ namespace E2ETests
if (applicationType == ApplicationType.Standalone)
{
deploymentParameters.AdditionalPublishParameters = "/p:RuntimeIdentifier=" + RuntimeEnvironment.GetRuntimeIdentifier();
deploymentParameters.AdditionalPublishParameters = " -r " + RuntimeEnvironment.GetRuntimeIdentifier();
}
// Override the connection strings using environment based configuration

View File

@ -161,7 +161,7 @@ namespace E2ETests
if (applicationType == ApplicationType.Standalone)
{
deploymentParameters.AdditionalPublishParameters = "--runtime " + RuntimeEnvironment.GetRuntimeIdentifier();
deploymentParameters.AdditionalPublishParameters = "-r " + RuntimeEnvironment.GetRuntimeIdentifier();
}
// Override the connection strings using environment based configuration

View File

@ -195,7 +195,7 @@ namespace E2ETests
if (applicationType == ApplicationType.Standalone)
{
deploymentParameters.AdditionalPublishParameters = "/p:RuntimeIdentifier=" + RuntimeEnvironment.GetRuntimeIdentifier();
deploymentParameters.AdditionalPublishParameters = " -r " + RuntimeEnvironment.GetRuntimeIdentifier();
}
// Override the connection strings using environment based configuration

View File

@ -13,6 +13,8 @@ using Xunit.Abstractions;
namespace E2ETests
{
// These tests publish(on the machine where these tests on run) the MusicStore app to a local folder first
// and then copy the published output to the target NanoServer and launch them.
public class SmokeTestsOnNanoServerUsingStandaloneRuntime : IDisposable
{
private readonly SmokeTestsOnNanoServer _smokeTestsOnNanoServer;
@ -263,6 +265,15 @@ namespace E2ETests
ApplicationBaseUriHint = applicationBaseUrl,
ApplicationType = applicationType
};
if (applicationType == ApplicationType.Standalone)
{
// Unable to use the RuntimeEnvironment.GetRuntimeIdentifier API here as NanoServer which is
// part of Windows Server 2016 has a RID of 'win10-x64' where as the CI servers currently
// run on Windows Server 2012 or less, which have different RIDs.
deploymentParameters.AdditionalPublishParameters = "-r win10-x64";
}
deploymentParameters.EnvironmentVariables.Add(
new KeyValuePair<string, string>("ASPNETCORE_ENVIRONMENT", "SocialTesting"));