Guard more earlier direct-file staging

This commit is contained in:
2026-06-13 09:35:23 +08:00
parent 6a64219533
commit a773c2e633
3 changed files with 59 additions and 65 deletions

View File

@@ -6504,12 +6504,7 @@
if (subsFollowMainNgcFiles.length !== 1 || new Set(subsFollowMainNgcFiles).size !== subsFollowMainNgcFiles.length) {
throw new Error("browser_interp_subs_follow_main_fixture_coverage: list drift");
}
const subsFollowMainStagedNgcFiles = [
subsFollowMainPath,
].map((path) => path.replace("/work/browser-interp/subs-follow-main/", ""));
if (subsFollowMainStagedNgcFiles.join(",") !== subsFollowMainNgcFiles.join(",")) {
throw new Error("browser_interp_subs_follow_main_staging_manifest: list drift");
}
assertInterpRegressionFileStaging("subs-follow-main", "test.ngc", subsFollowMainPath);
verifyExpectedOutput(
"browser_interp_subs_follow_main",
interp.runFile(subsFollowMainPath),
@@ -6534,12 +6529,7 @@
if (fractionalLinenumbersNgcFiles.length !== 1 || new Set(fractionalLinenumbersNgcFiles).size !== fractionalLinenumbersNgcFiles.length) {
throw new Error("browser_interp_fractional_linenumbers_fixture_coverage: list drift");
}
const fractionalLinenumbersStagedNgcFiles = [
fractionalLinenumbersPath,
].map((path) => path.replace("/work/browser-interp/fractional-linenumbers/", ""));
if (fractionalLinenumbersStagedNgcFiles.join(",") !== fractionalLinenumbersNgcFiles.join(",")) {
throw new Error("browser_interp_fractional_linenumbers_staging_manifest: list drift");
}
assertInterpRegressionFileStaging("fractional-linenumbers", "test.ngc", fractionalLinenumbersPath);
verifyExpectedOutput(
"browser_interp_fractional_linenumbers",
interp.runFile(fractionalLinenumbersPath),
@@ -6565,12 +6555,7 @@
if (crazyPathsNgcFiles.length !== 1 || new Set(crazyPathsNgcFiles).size !== crazyPathsNgcFiles.length) {
throw new Error("browser_interp_crazy_paths_fixture_coverage: list drift");
}
const crazyPathsStagedNgcFiles = [
crazyPathsPath,
].map((path) => path.replace("/work/browser-interp/crazy-paths/", ""));
if (crazyPathsStagedNgcFiles.join(",") !== crazyPathsNgcFiles.join(",")) {
throw new Error("browser_interp_crazy_paths_staging_manifest: list drift");
}
assertInterpRegressionFileStaging("crazy-paths", "test.ngc", crazyPathsPath);
verifyExpectedOutput(
"browser_interp_crazy_paths",
interp.runFile(crazyPathsPath),
@@ -6667,12 +6652,7 @@
if (namedparamBug424NgcFiles.length !== 1 || new Set(namedparamBug424NgcFiles).size !== namedparamBug424NgcFiles.length) {
throw new Error("browser_interp_namedparam_bug424_fixture_coverage: list drift");
}
const namedparamBug424StagedNgcFiles = [
namedparamBug424Path,
].map((path) => path.replace("/work/browser-interp/namedparam-bug424/", ""));
if (namedparamBug424StagedNgcFiles.join(",") !== namedparamBug424NgcFiles.join(",")) {
throw new Error("browser_interp_namedparam_bug424_staging_manifest: list drift");
}
assertInterpRegressionFileStaging("namedparam-bug424", "test.ngc", namedparamBug424Path);
verifyExpectedOutput(
"browser_interp_namedparam_bug424",
interp.runFile(namedparamBug424Path),
@@ -6700,12 +6680,7 @@
if (flowsnakeNgcFiles.length !== 1 || new Set(flowsnakeNgcFiles).size !== flowsnakeNgcFiles.length) {
throw new Error("browser_interp_flowsnake_fixture_coverage: list drift");
}
const flowsnakeStagedNgcFiles = [
flowsnakePath,
].map((path) => path.replace("/work/browser-interp/flowsnake/", ""));
if (flowsnakeStagedNgcFiles.join(",") !== flowsnakeNgcFiles.join(",")) {
throw new Error("browser_interp_flowsnake_staging_manifest: list drift");
}
assertInterpRegressionFileStaging("flowsnake", "flowsnake.ngc", flowsnakePath);
verifyExpectedOutput(
"browser_interp_flowsnake",
interp.runFile(flowsnakePath),

View File

@@ -1487,13 +1487,7 @@ assert.deepEqual(
interpRegressionNgcFilesRecursive("subs-follow-main"),
"interp subs-follow-main fixture coverage drift",
);
assert.deepEqual(
[
subsFollowMainPath,
],
subsFollowMainNgcFiles.map((file) => `/work/interp/subs-follow-main/${file}`),
"interp subs-follow-main staging manifest drift",
);
assertInterpRegressionFileStaging("subs-follow-main", "test.ngc", subsFollowMainPath);
verifyExpectedOutput(
"interp_subs_follow_main_wasm",
interp.runFile(subsFollowMainPath),
@@ -1519,13 +1513,7 @@ assert.deepEqual(
interpRegressionNgcFilesRecursive("fractional-linenumbers"),
"interp fractional-linenumbers fixture coverage drift",
);
assert.deepEqual(
[
fractionalLinenumbersPath,
],
fractionalLinenumbersNgcFiles.map((file) => `/work/interp/fractional-linenumbers/${file}`),
"interp fractional-linenumbers staging manifest drift",
);
assertInterpRegressionFileStaging("fractional-linenumbers", "test.ngc", fractionalLinenumbersPath);
verifyExpectedOutput(
"interp_fractional_linenumbers_wasm",
interp.runFile(fractionalLinenumbersPath),
@@ -1549,13 +1537,7 @@ assert.deepEqual(
interpRegressionNgcFilesRecursive("crazy-paths"),
"interp crazy-paths fixture coverage drift",
);
assert.deepEqual(
[
crazyPathsPath,
],
crazyPathsNgcFiles.map((file) => `/work/interp/crazy-paths/${file}`),
"interp crazy-paths staging manifest drift",
);
assertInterpRegressionFileStaging("crazy-paths", "test.ngc", crazyPathsPath);
verifyExpectedOutput(
"interp_crazy_paths_wasm",
interp.runFile(crazyPathsPath),
@@ -1644,13 +1626,7 @@ assert.deepEqual(
interpRegressionNgcFilesRecursive("namedparam-bug424"),
"interp namedparam-bug424 fixture coverage drift",
);
assert.deepEqual(
[
namedparamBug424Path,
],
namedparamBug424NgcFiles.map((file) => `/work/interp/namedparam-bug424/${file}`),
"interp namedparam-bug424 staging manifest drift",
);
assertInterpRegressionFileStaging("namedparam-bug424", "test.ngc", namedparamBug424Path);
verifyExpectedOutput(
"interp_namedparam_bug424_wasm",
interp.runFile(namedparamBug424Path),
@@ -1676,13 +1652,7 @@ assert.deepEqual(
interpRegressionNgcFilesRecursive("flowsnake"),
"interp flowsnake fixture coverage drift",
);
assert.deepEqual(
[
flowsnakePath,
],
flowsnakeNgcFiles.map((file) => `/work/interp/flowsnake/${file}`),
"interp flowsnake staging manifest drift",
);
assertInterpRegressionFileStaging("flowsnake", "flowsnake.ngc", flowsnakePath);
verifyExpectedOutput(
"interp_flowsnake_wasm",
interp.runFile(flowsnakePath),