Skip to content

Commit c898079

Browse files
committed
[wasm] WBT: convert sdk path to full, if needed
1 parent 3869e63 commit c898079

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/tests/BuildWasmApps/Wasm.Build.Tests/BuildEnvironment.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ public BuildEnvironment()
6060
if (!Directory.Exists(sdkForWorkloadPath))
6161
throw new Exception($"Could not find SDK_FOR_WORKLOAD_TESTING_PATH={sdkForWorkloadPath}");
6262

63+
if (!Path.IsPathRooted(sdkForWorkloadPath))
64+
sdkForWorkloadPath = Path.GetFullPath(sdkForWorkloadPath);
65+
6366
EnvVars = new Dictionary<string, string>();
6467
bool workloadInstalled = EnvironmentVariables.SdkHasWorkloadInstalled != null && EnvironmentVariables.SdkHasWorkloadInstalled == "true";
6568
if (workloadInstalled)
@@ -71,7 +74,7 @@ public BuildEnvironment()
7174
WorkloadPacksDir = Path.Combine(sdkForWorkloadPath, "packs");
7275
WorkloadPacksVersion = workloadPacksVersion;
7376

74-
RuntimePackDir = Path.Combine(sdkForWorkloadPath, "packs", "Microsoft.NETCore.App.Runtime.Mono.browser-wasm", WorkloadPacksVersion);
77+
RuntimePackDir = Path.Combine(WorkloadPacksDir, "Microsoft.NETCore.App.Runtime.Mono.browser-wasm", WorkloadPacksVersion);
7578
DirectoryBuildPropsContents = s_directoryBuildPropsForWorkloads;
7679
DirectoryBuildTargetsContents = s_directoryBuildTargetsForWorkloads;
7780

0 commit comments

Comments
 (0)