diff --git a/src/mono/wasm/Wasm.Build.Tests/Blazor/BuildPublishTests.cs b/src/mono/wasm/Wasm.Build.Tests/Blazor/BuildPublishTests.cs index e7be07f71c89e..fc22d03b303bc 100644 --- a/src/mono/wasm/Wasm.Build.Tests/Blazor/BuildPublishTests.cs +++ b/src/mono/wasm/Wasm.Build.Tests/Blazor/BuildPublishTests.cs @@ -28,7 +28,7 @@ public BuildPublishTests(ITestOutputHelper output, SharedBuildPerTestClassFixtur [InlineData("Release")] public async Task DefaultTemplate_WithoutWorkload(string config) { - string id = $"blz_no_workload_{config}_{GetRandomId()}_{s_unicodeChar}"; + string id = $"blz_no_workload_{config}_{GetRandomId()}_{s_unicodeChars}"; CreateBlazorWasmTemplateProject(id); BlazorBuild(new BlazorBuildOptions(id, config)); @@ -63,7 +63,7 @@ public static TheoryData TestDataForDefaultTemplate_WithWorkload(b public void DefaultTemplate_NoAOT_WithWorkload(string config, bool testUnicode) { string id = testUnicode ? - $"blz_no_aot_{config}_{GetRandomId()}_{s_unicodeChar}" : + $"blz_no_aot_{config}_{GetRandomId()}_{s_unicodeChars}" : $"blz_no_aot_{config}_{GetRandomId()}"; CreateBlazorWasmTemplateProject(id); @@ -84,7 +84,7 @@ public void DefaultTemplate_NoAOT_WithWorkload(string config, bool testUnicode) public void DefaultTemplate_AOT_WithWorkload(string config, bool testUnicode) { string id = testUnicode ? - $"blz_aot_{config}_{GetRandomId()}_{s_unicodeChar}" : + $"blz_aot_{config}_{GetRandomId()}_{s_unicodeChars}" : $"blz_aot_{config}_{GetRandomId()}"; CreateBlazorWasmTemplateProject(id); diff --git a/src/mono/wasm/Wasm.Build.Tests/Blazor/MiscTests3.cs b/src/mono/wasm/Wasm.Build.Tests/Blazor/MiscTests3.cs index 10717b334174b..eeaf368640e92 100644 --- a/src/mono/wasm/Wasm.Build.Tests/Blazor/MiscTests3.cs +++ b/src/mono/wasm/Wasm.Build.Tests/Blazor/MiscTests3.cs @@ -33,7 +33,7 @@ public MiscTests3(ITestOutputHelper output, SharedBuildPerTestClassFixture build public async Task WithDllImportInMainAssembly(string config, bool build, bool publish) { // Based on https://github.com/dotnet/runtime/issues/59255 - string id = $"blz_dllimp_{config}_{s_unicodeChar}"; + string id = $"blz_dllimp_{config}_{s_unicodeChars}"; if (build && publish) id += "build_then_publish"; else if (build) diff --git a/src/mono/wasm/Wasm.Build.Tests/BuildPublishTests.cs b/src/mono/wasm/Wasm.Build.Tests/BuildPublishTests.cs index d171631c2c5e0..f287fa4574164 100644 --- a/src/mono/wasm/Wasm.Build.Tests/BuildPublishTests.cs +++ b/src/mono/wasm/Wasm.Build.Tests/BuildPublishTests.cs @@ -158,7 +158,7 @@ void CheckOutputForNativeBuild(bool expectAOT, bool expectRelinking, BuildArgs b { if (testUnicode) { - string projectNameCore = buildArgs.ProjectName.Trim(new char[] {s_unicodeChar}); + string projectNameCore = buildArgs.ProjectName.Replace(s_unicodeChars, ""); TestUtils.AssertMatches(@$"{projectNameCore}\S+.dll -> {projectNameCore}\S+.dll.bc", buildOutput, contains: expectAOT); TestUtils.AssertMatches(@$"{projectNameCore}\S+.dll.bc -> {projectNameCore}\S+.dll.o", buildOutput, contains: expectAOT); } diff --git a/src/mono/wasm/Wasm.Build.Tests/BuildTestBase.cs b/src/mono/wasm/Wasm.Build.Tests/BuildTestBase.cs index f871c3d2bfe7b..03db9aed60118 100644 --- a/src/mono/wasm/Wasm.Build.Tests/BuildTestBase.cs +++ b/src/mono/wasm/Wasm.Build.Tests/BuildTestBase.cs @@ -29,7 +29,7 @@ public abstract class BuildTestBase : IClassFixture - appendUnicode ? $"{prefix}_{config}_{s_unicodeChar}" : $"{prefix}_{config}"; + appendUnicode ? $"{prefix}_{config}_{s_unicodeChars}" : $"{prefix}_{config}"; } }