diff --git a/src/MusicStore/Program.cs b/src/MusicStore/Program.cs index d51e4216da..9a31490993 100644 --- a/src/MusicStore/Program.cs +++ b/src/MusicStore/Program.cs @@ -8,7 +8,7 @@ namespace MusicStore { var host = new WebHostBuilder() .UseDefaultHostingConfiguration(args) - .UseIISPlatformHandlerUrl() + .UseIIS() .UseStartup("MusicStore") .Build(); diff --git a/src/MusicStore/project.json b/src/MusicStore/project.json index 088644327e..2e087e410a 100644 --- a/src/MusicStore/project.json +++ b/src/MusicStore/project.json @@ -17,7 +17,6 @@ "../../shared/**/*.cs" ], "tools": { - "dotnet-publish-iis": "1.0.0-*", "dotnet-razor-tooling": "1.0.0-*" }, "content": [ @@ -37,9 +36,9 @@ "Microsoft.AspNetCore.Diagnostics": "1.0.0-*", "Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore": "1.0.0-*", "Microsoft.AspNetCore.Identity.EntityFrameworkCore": "1.0.0-*", - "Microsoft.AspNetCore.IISPlatformHandler": "1.0.0-*", "Microsoft.AspNetCore.Mvc": "1.0.0-*", "Microsoft.AspNetCore.Mvc.TagHelpers": "1.0.0-*", + "Microsoft.AspNetCore.Server.IISIntegration": "1.0.0-*", "Microsoft.AspNetCore.Server.Kestrel": "1.0.0-*", "Microsoft.AspNetCore.Server.WebListener": "0.1.0-*", "Microsoft.AspNetCore.Session": "1.0.0-*", @@ -69,10 +68,5 @@ "portable-net451+win8" ] } - }, - "scripts": { - "postpublish": [ - "dotnet publish-iis --publish-folder %publish:OutputPath%" - ] } } \ No newline at end of file diff --git a/src/MusicStore/wwwroot/web.config b/src/MusicStore/wwwroot/web.config index a0ee658c30..6e69d15802 100644 --- a/src/MusicStore/wwwroot/web.config +++ b/src/MusicStore/wwwroot/web.config @@ -1,12 +1,9 @@  - - - - - - - - - + + + + + + \ No newline at end of file diff --git a/test/E2ETests/Http.config b/test/E2ETests/Http.config new file mode 100644 index 0000000000..94a115e54b --- /dev/null +++ b/test/E2ETests/Http.config @@ -0,0 +1,1029 @@ + + + + + + + + +
+
+
+
+
+
+
+
+ + + +
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ +
+
+ +
+
+
+
+
+
+ +
+
+
+
+
+ +
+
+
+ +
+
+ +
+
+ +
+
+
+ + +
+
+
+
+
+
+ +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/test/E2ETests/Implementation/Validator.cs b/test/E2ETests/Implementation/Validator.cs index 1011b1c6c0..fe3b079a91 100644 --- a/test/E2ETests/Implementation/Validator.cs +++ b/test/E2ETests/Implementation/Validator.cs @@ -200,13 +200,7 @@ namespace E2ETests private string PrefixBaseAddress(string url) { -#if DNX451 - url = _deploymentResult.DeploymentParameters.ServerType == ServerType.IIS ? - string.Format(url, new Uri(_deploymentResult.ApplicationBaseUri).Segments[1].TrimEnd('/')) : - string.Format(url, string.Empty); -#else url = string.Format(url, string.Empty); -#endif return url.Replace("//", "/").Replace("%2F%2F", "%2F").Replace("%2F/", "%2F"); } diff --git a/test/E2ETests/NtlmAuthentation.config b/test/E2ETests/NtlmAuthentation.config index d14f5fc1f2..9d098eee84 100644 --- a/test/E2ETests/NtlmAuthentation.config +++ b/test/E2ETests/NtlmAuthentation.config @@ -118,6 +118,7 @@
+
@@ -252,6 +253,7 @@ + @@ -926,6 +928,7 @@ + diff --git a/test/E2ETests/NtlmAuthentationTest.cs b/test/E2ETests/NtlmAuthentationTest.cs index 59d7018643..f485548ccc 100644 --- a/test/E2ETests/NtlmAuthentationTest.cs +++ b/test/E2ETests/NtlmAuthentationTest.cs @@ -26,6 +26,7 @@ namespace E2ETests [OSSkipCondition(OperatingSystems.Linux)] [OSSkipCondition(OperatingSystems.MacOSX)] [InlineData(ServerType.WebListener, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5050/")] + [InlineData(ServerType.IISExpress, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5051/")] public async Task NtlmAuthenticationTest(ServerType serverType, RuntimeFlavor runtimeFlavor, RuntimeArchitecture architecture, string applicationBaseUrl) { using (_logger.BeginScope("NtlmAuthenticationTest")) @@ -35,7 +36,7 @@ namespace E2ETests var deploymentParameters = new DeploymentParameters(Helpers.GetApplicationPath(), serverType, runtimeFlavor, architecture) { PublishApplicationBeforeDeployment = true, - PublishTargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "dnx451" : "netstandardapp1.5", + PublishTargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netstandardapp1.5", ApplicationBaseUriHint = applicationBaseUrl, EnvironmentName = "NtlmAuthentication", //Will pick the Start class named 'StartupNtlmAuthentication' ApplicationHostConfigTemplateContent = (serverType == ServerType.IISExpress) ? File.ReadAllText("NtlmAuthentation.config") : null, diff --git a/test/E2ETests/OpenIdConnectTests.cs b/test/E2ETests/OpenIdConnectTests.cs index 8af71af019..96845666e8 100644 --- a/test/E2ETests/OpenIdConnectTests.cs +++ b/test/E2ETests/OpenIdConnectTests.cs @@ -63,7 +63,7 @@ namespace E2ETests var deploymentParameters = new DeploymentParameters(Helpers.GetApplicationPath(), serverType, runtimeFlavor, architecture) { PublishApplicationBeforeDeployment = true, - PublishTargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "dnx451" : "netstandardapp1.5", + PublishTargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netstandardapp1.5", ApplicationBaseUriHint = applicationBaseUrl, EnvironmentName = "OpenIdConnectTesting", UserAdditionalCleanup = parameters => diff --git a/test/E2ETests/PublishAndRunTests.cs b/test/E2ETests/PublishAndRunTests.cs index b10ab524c7..452db21447 100644 --- a/test/E2ETests/PublishAndRunTests.cs +++ b/test/E2ETests/PublishAndRunTests.cs @@ -139,7 +139,7 @@ namespace E2ETests { ApplicationBaseUriHint = applicationBaseUrl, PublishApplicationBeforeDeployment = true, - PublishTargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "dnx451" : "netstandardapp1.5", + PublishTargetFramework = runtimeFlavor == RuntimeFlavor.Clr ? "net451" : "netstandardapp1.5", UserAdditionalCleanup = parameters => { DbUtils.DropDatabase(musicStoreDbName, _logger); diff --git a/test/E2ETests/SmokeTests.cs b/test/E2ETests/SmokeTests.cs index f456acd7de..bb07467033 100644 --- a/test/E2ETests/SmokeTests.cs +++ b/test/E2ETests/SmokeTests.cs @@ -1,4 +1,5 @@ using System; +using System.IO; using System.Collections.Generic; using System.Net; using System.Net.Http; @@ -31,6 +32,8 @@ namespace E2ETests [InlineData(ServerType.WebListener, RuntimeFlavor.CoreClr, RuntimeArchitecture.x86, "http://localhost:5002/")] [InlineData(ServerType.Kestrel, RuntimeFlavor.Clr, RuntimeArchitecture.x86, "http://localhost:5003/")] [InlineData(ServerType.Kestrel, RuntimeFlavor.CoreClr, RuntimeArchitecture.x86, "http://localhost:5004/")] + [InlineData(ServerType.IISExpress, RuntimeFlavor.Clr, RuntimeArchitecture.x86, "http://localhost:5005/")] + [InlineData(ServerType.IISExpress, RuntimeFlavor.CoreClr, RuntimeArchitecture.x86, "http://localhost:5006/")] public async Task WindowsOS( ServerType serverType, RuntimeFlavor runtimeFlavor, @@ -43,7 +46,7 @@ namespace E2ETests [ConditionalTheory(Skip = "Temporarily disabling test"), Trait("E2Etests", "Smoke")] [OSSkipCondition(OperatingSystems.Windows)] - [InlineData(ServerType.Kestrel, RuntimeFlavor.Clr, RuntimeArchitecture.x86, "http://localhost:5005/")] + [InlineData(ServerType.Kestrel, RuntimeFlavor.Clr, RuntimeArchitecture.x86, "http://localhost:5007/")] public async Task NonWindowsOS( ServerType serverType, RuntimeFlavor runtimeFlavor, @@ -72,10 +75,12 @@ namespace E2ETests [ConditionalTheory, Trait("E2Etests", "Smoke")] [OSSkipCondition(OperatingSystems.Linux)] [OSSkipCondition(OperatingSystems.MacOSX)] - //[InlineData(ServerType.WebListener, RuntimeFlavor.Clr, RuntimeArchitecture.x64, "http://localhost:5006/")] - //[InlineData(ServerType.WebListener, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5007/")] - //[InlineData(ServerType.Kestrel, RuntimeFlavor.Clr, RuntimeArchitecture.x64, "http://localhost:5008/")] - [InlineData(ServerType.Kestrel, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5009/")] + [InlineData(ServerType.WebListener, RuntimeFlavor.Clr, RuntimeArchitecture.x64, "http://localhost:5008/")] + [InlineData(ServerType.WebListener, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5009/")] + [InlineData(ServerType.Kestrel, RuntimeFlavor.Clr, RuntimeArchitecture.x64, "http://localhost:5010/")] + [InlineData(ServerType.Kestrel, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5011/")] + [InlineData(ServerType.IISExpress, RuntimeFlavor.Clr, RuntimeArchitecture.x64, "http://localhost:5012/")] + [InlineData(ServerType.IISExpress, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5013/")] public async Task WindowsOS( ServerType serverType, RuntimeFlavor runtimeFlavor, @@ -88,7 +93,7 @@ namespace E2ETests [ConditionalTheory, Trait("E2Etests", "Smoke")] [OSSkipCondition(OperatingSystems.Windows)] - [InlineData(ServerType.Kestrel, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5011/")] + [InlineData(ServerType.Kestrel, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5014/")] public async Task NonWindowsOS( ServerType serverType, RuntimeFlavor runtimeFlavor, @@ -118,8 +123,8 @@ namespace E2ETests [OSSkipCondition(OperatingSystems.Linux)] [SkipIfCurrentRuntimeIsCoreClr] [SkipIfIISVariationsNotEnabled] - //[InlineData(ServerType.IIS, RuntimeFlavor.Clr, RuntimeArchitecture.x86, "http://localhost:5012/")] - [InlineData(ServerType.IIS, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5013/")] + //[InlineData(ServerType.IIS, RuntimeFlavor.Clr, RuntimeArchitecture.x86, "http://localhost:5015/")] + [InlineData(ServerType.IIS, RuntimeFlavor.CoreClr, RuntimeArchitecture.x64, "http://localhost:5016/")] public async Task SmokeTestSuite_On_IIS_X86( ServerType serverType, RuntimeFlavor runtimeFlavor, @@ -162,8 +167,10 @@ namespace E2ETests { ApplicationBaseUriHint = applicationBaseUrl, EnvironmentName = "SocialTesting", + ApplicationHostConfigTemplateContent = (serverType == ServerType.IISExpress) ? File.ReadAllText("Http.config") : null, + SiteName = "MusicStoreTestSite", PublishApplicationBeforeDeployment = true, - PublishTargetFramework = donetFlavor == RuntimeFlavor.Clr ? "dnx451" : "netstandardapp1.5", + PublishTargetFramework = donetFlavor == RuntimeFlavor.Clr ? "net451" : "netstandardapp1.5", UserAdditionalCleanup = parameters => { DbUtils.DropDatabase(musicStoreDbName, _logger);