Guard m98m99 direct-file staging helper
This commit is contained in:
@@ -276,6 +276,14 @@ function writeInterpRegressionFile(name, filename) {
|
||||
return `${wasmDir}/${filename}`;
|
||||
}
|
||||
|
||||
function assertInterpRegressionFileStaging(name, filename, wasmPath) {
|
||||
assert.equal(
|
||||
wasmPath,
|
||||
`/work/interp/${name}/${filename}`,
|
||||
`interp ${name}/${filename} staging manifest drift`,
|
||||
);
|
||||
}
|
||||
|
||||
function writeInterpRegressionFiles(name, files) {
|
||||
const sourceDir = resolve(rootDir, "vendor/linuxcnc/tests/interp", name);
|
||||
const wasmDir = `/work/interp/${name}`;
|
||||
@@ -2857,6 +2865,7 @@ assert.deepEqual(
|
||||
);
|
||||
|
||||
const m98m99BasicsPath = writeInterpRegressionFile("m98m99/01-basics", "test.ngc");
|
||||
assertInterpRegressionFileStaging("m98m99/01-basics", "test.ngc", m98m99BasicsPath);
|
||||
verifyExpectedOutput(
|
||||
"interp_m98m99_01_basics_wasm",
|
||||
interp.runFile(m98m99BasicsPath),
|
||||
@@ -2873,6 +2882,7 @@ verifyExpectedOutput(
|
||||
);
|
||||
|
||||
const m98m99VariablesPath = writeInterpRegressionFile("m98m99/02-variables", "test.ngc");
|
||||
assertInterpRegressionFileStaging("m98m99/02-variables", "test.ngc", m98m99VariablesPath);
|
||||
const m98m99VariablesRun = runWithCapturedPrints(() => interp.runFile(m98m99VariablesPath));
|
||||
verifyExpectedOutput(
|
||||
"interp_m98m99_02_variables_wasm",
|
||||
@@ -2899,16 +2909,10 @@ const m98m99M98NoPWordPath = writeInterpRegressionFile(
|
||||
"m98m99/03-error-M98-no-P-word",
|
||||
"test.ngc",
|
||||
);
|
||||
assert.deepEqual(
|
||||
[
|
||||
m98m99BasicsPath,
|
||||
m98m99VariablesPath,
|
||||
m98m99M98NoPWordPath,
|
||||
],
|
||||
m98m99RegressionFiles
|
||||
.slice(0, 3)
|
||||
.map((file) => `/work/interp/m98m99/${file}`),
|
||||
"interp m98m99 initial direct-file staging manifest drift",
|
||||
assertInterpRegressionFileStaging(
|
||||
"m98m99/03-error-M98-no-P-word",
|
||||
"test.ngc",
|
||||
m98m99M98NoPWordPath,
|
||||
);
|
||||
verifyExpectedOutput(
|
||||
"interp_m98m99_03_error_m98_no_p_word_wasm",
|
||||
@@ -3397,12 +3401,10 @@ const m98m99OExpressionCallPath = writeInterpRegressionFile(
|
||||
"m98m99/14-o-expression-call",
|
||||
"test.ngc",
|
||||
);
|
||||
assert.deepEqual(
|
||||
[m98m99OExpressionCallPath],
|
||||
m98m99RegressionFiles
|
||||
.slice(23, 24)
|
||||
.map((file) => `/work/interp/m98m99/${file}`),
|
||||
"interp m98m99 final o-expression direct-file staging manifest drift",
|
||||
assertInterpRegressionFileStaging(
|
||||
"m98m99/14-o-expression-call",
|
||||
"test.ngc",
|
||||
m98m99OExpressionCallPath,
|
||||
);
|
||||
const m98m99OExpressionCallRun = runWithCapturedPrints(() =>
|
||||
interp.runFile(m98m99OExpressionCallPath),
|
||||
|
||||
Reference in New Issue
Block a user