diff --git a/src/Components/Blazor.sln b/src/Components/Blazor.sln index 6070e8a197..707b6c87f0 100644 --- a/src/Components/Blazor.sln +++ b/src/Components/Blazor.sln @@ -109,7 +109,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Compon EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Components.WebAssembly.Server.Tests", "WebAssembly\Server\test\Microsoft.AspNetCore.Components.WebAssembly.Server.Tests.csproj", "{72D3D00C-5281-455F-9E19-646EE766009A}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Components.WebAssembly.HttpHandler", "WebAssembly\WebAssemblyHttpHandler\src\Microsoft.AspNetCore.Comopnents.WebAssembly.HttpHandler.csproj", "{52744BCB-1046-48C0-93A4-19A311A907B2}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.Components.WebAssembly.HttpHandler", "WebAssembly\WebAssemblyHttpHandler\src\Microsoft.AspNetCore.Components.WebAssembly.HttpHandler.csproj", "{52744BCB-1046-48C0-93A4-19A311A907B2}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution diff --git a/src/Components/WebAssembly/Build/src/targets/Publish.targets b/src/Components/WebAssembly/Build/src/targets/Publish.targets index feb3524e1f..5847bb0aca 100644 --- a/src/Components/WebAssembly/Build/src/targets/Publish.targets +++ b/src/Components/WebAssembly/Build/src/targets/Publish.targets @@ -15,31 +15,26 @@ Condition="'$(BlazorPrunePublishOutput)' != 'false'"> - + - - - - + Condition="'%(ResolvedFileToPublish.RelativePath)' != 'web.config' AND !$([System.String]::Copy('%(ResolvedFileToPublish.RelativePath)').Replace('\','/').StartsWith('wwwroot/'))"/> - - + AfterTargets="_BlazorCleanupPublishOutput;ComputeResolvedFilesToPublishList" + Condition="'@(ResolvedFileToPublish->AnyHaveMetadataValue('RelativePath', 'web.config'))' != 'true'"> + + + + true + PreserveNewest + web.config + + + - + \ No newline at end of file diff --git a/src/Components/WebAssembly/Build/test/BuildIntegrationTests/PublishIntegrationTest.cs b/src/Components/WebAssembly/Build/test/BuildIntegrationTests/PublishIntegrationTest.cs index cd905e7d52..cb9957fcbc 100644 --- a/src/Components/WebAssembly/Build/test/BuildIntegrationTests/PublishIntegrationTest.cs +++ b/src/Components/WebAssembly/Build/test/BuildIntegrationTests/PublishIntegrationTest.cs @@ -117,8 +117,6 @@ namespace Microsoft.AspNetCore.Components.WebAssembly.Build var publishDirectory = project.PublishOutputDirectory; - var blazorPublishDirectory = Path.Combine(publishDirectory, "wwwroot"); - // Verify web.config Assert.FileExists(result, publishDirectory, "web.config"); Assert.FileContains(result, Path.Combine(publishDirectory, "web.config"), webConfigContents); @@ -421,7 +419,6 @@ namespace Microsoft.AspNetCore.Components.WebAssembly.Build File.WriteAllText(path, content); } - private static void VerifyBootManifestHashes(MSBuildResult result, string blazorPublishDirectory) { var bootManifestResolvedPath = Assert.FileExists(result, blazorPublishDirectory, "_framework", "blazor.boot.json");