diff --git a/test/E2ETests/Common/Helpers.cs b/test/E2ETests/Common/Helpers.cs index ca480a8c61..0481550d24 100644 --- a/test/E2ETests/Common/Helpers.cs +++ b/test/E2ETests/Common/Helpers.cs @@ -40,5 +40,16 @@ namespace E2ETests File.WriteAllText(overrideConfig, "{\"UseInMemoryDatabase\": \"true\"}"); } } + + public static string GetCurrentBuildConfiguration() + { + var configuration = "Debug"; + if (string.Equals(Environment.GetEnvironmentVariable("Configuration"), "Release", StringComparison.OrdinalIgnoreCase)) + { + configuration = "Release"; + } + + return configuration; + } } } \ No newline at end of file diff --git a/test/E2ETests/NtlmAuthentationTest.cs b/test/E2ETests/NtlmAuthentationTest.cs index 59939b6265..1c0db6b424 100644 --- a/test/E2ETests/NtlmAuthentationTest.cs +++ b/test/E2ETests/NtlmAuthentationTest.cs @@ -39,6 +39,7 @@ namespace E2ETests { PublishApplicationBeforeDeployment = true, TargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netcoreapp1.0", + Configuration = Helpers.GetCurrentBuildConfiguration(), ApplicationType = applicationType, ApplicationBaseUriHint = applicationBaseUrl, EnvironmentName = "NtlmAuthentication", //Will pick the Start class named 'StartupNtlmAuthentication' diff --git a/test/E2ETests/OpenIdConnectTests.cs b/test/E2ETests/OpenIdConnectTests.cs index 1972201419..dc7bf573d5 100644 --- a/test/E2ETests/OpenIdConnectTests.cs +++ b/test/E2ETests/OpenIdConnectTests.cs @@ -67,6 +67,7 @@ namespace E2ETests { PublishApplicationBeforeDeployment = true, TargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netcoreapp1.0", + Configuration = Helpers.GetCurrentBuildConfiguration(), ApplicationType = applicationType, ApplicationBaseUriHint = applicationBaseUrl, EnvironmentName = "OpenIdConnectTesting", diff --git a/test/E2ETests/PublishAndRunTests.cs b/test/E2ETests/PublishAndRunTests.cs index 19c95a5732..f25cdd2074 100644 --- a/test/E2ETests/PublishAndRunTests.cs +++ b/test/E2ETests/PublishAndRunTests.cs @@ -149,6 +149,7 @@ namespace E2ETests ApplicationBaseUriHint = applicationBaseUrl, PublishApplicationBeforeDeployment = true, TargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netcoreapp1.0", + Configuration = Helpers.GetCurrentBuildConfiguration(), ApplicationType = applicationType, UserAdditionalCleanup = parameters => { diff --git a/test/E2ETests/SmokeTests.cs b/test/E2ETests/SmokeTests.cs index bbec457924..b47d71722c 100644 --- a/test/E2ETests/SmokeTests.cs +++ b/test/E2ETests/SmokeTests.cs @@ -185,6 +185,7 @@ namespace E2ETests SiteName = "MusicStoreTestSite", PublishApplicationBeforeDeployment = true, TargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netcoreapp1.0", + Configuration = Helpers.GetCurrentBuildConfiguration(), ApplicationType = applicationType, UserAdditionalCleanup = parameters => {