Skip to content

Commit c6ea149

Browse files
committed
[wasm] Fix failing blazor tests to handle disabled fingerprinting
Fixes dotnet#86959 .
1 parent 3c0c801 commit c6ea149

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/mono/wasm/Wasm.Build.Tests/BuildTestBase.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -822,7 +822,7 @@ protected static void AssertFile(string file0, string file1, string? label = nul
822822
return result;
823823
}
824824

825-
protected void AssertBlazorBundle(string config, bool isPublish, bool dotnetWasmFromRuntimePack, string targetFramework = DefaultTargetFrameworkForBlazor, string? binFrameworkDir = null)
825+
protected void AssertBlazorBundle(string config, bool isPublish, bool dotnetWasmFromRuntimePack, string targetFramework = DefaultTargetFrameworkForBlazor, string? binFrameworkDir = null, bool expectFingerprinting = false)
826826
{
827827
binFrameworkDir ??= FindBlazorBinFrameworkDir(config, isPublish, targetFramework);
828828

@@ -832,7 +832,7 @@ protected void AssertBlazorBundle(string config, bool isPublish, bool dotnetWasm
832832
"Expected dotnet.native.wasm to be same as the runtime pack",
833833
same: dotnetWasmFromRuntimePack);
834834

835-
string? dotnetJsPath = Directory.EnumerateFiles(binFrameworkDir, "dotnet.native.*.js").FirstOrDefault();
835+
string? dotnetJsPath = Directory.EnumerateFiles(binFrameworkDir, expectFingerprinting ? "dotnet.native.*.js" : "dotnet.native.js").FirstOrDefault();
836836
Assert.True(dotnetJsPath != null, $"Could not find blazor's dotnet*js in {binFrameworkDir}");
837837

838838
AssertFile(Path.Combine(s_buildEnv.GetRuntimeNativeDir(targetFramework), "dotnet.native.js"),

0 commit comments

Comments
 (0)