Relocate the prebuilt lib diagnostics path when installing the native command (#2300)

This commit is contained in:
Chris Tate
2026-10-25 22:12:41 -05:00
committed by GitHub
2 changed files with 5 additions and 0 deletions
+1
View File
@@ -49,6 +49,7 @@ export function relocateToolchain(manifest, sourceDirectory, destinationDirector
"declarations",
"comptime",
"wasi_node_runner",
"lib_diagnostics",
]) {
if (typeof relocated[name] === "string") relocated[name] = pathFrom(relocated[name]);
}
+4
View File
@@ -53,6 +53,7 @@ function fixture() {
dsymutil: "dsymutil",
comptime: "../lib/comptime",
wasi_node_runner: "../lib/wasi/cli/wasi-runner.js",
lib_diagnostics: "../lib/lib-diagnostics.json",
};
writeFileSync(binary + ".json", JSON.stringify(toolchain));
const helpers = [
@@ -93,6 +94,9 @@ test("installs a direct executable and relocatable references to platform assets
expect(resolve(dirname(installed), manifest.wasi_node_runner)).toBe(
join(platform, "wasi/cli/wasi-runner.js"),
);
expect(resolve(dirname(installed), manifest.lib_diagnostics)).toBe(
join(platform, "lib-diagnostics.json"),
);
expect(resolve(dirname(installed), manifest.runtime_packs[0].path)).toBe(
join(platform, "runtime"),
);