Skip to content

Commit 07968b5

Browse files
fix(scripts): resolve check-migration-journal.mjs path via repoRoot, not undefined scriptsDir
master (fork/master @ 491c36f, landed via RBR-1033/#14) shipped runMigrationJournalGuard() referencing an undefined 'scriptsDir' variable in scripts/run-vitest-stable.mjs. This throws a ReferenceError before any test suite starts, breaking every 'general' and 'serialized' vitest invocation on master right now (confirmed live: general-server shard 1/30 crashes immediately without this fix, succeeds with it). The guard script (scripts/check-migration-journal.mjs) and its own dedicated tests are correct; only this call site had the wrong identifier — repoRoot was already defined and used everywhere else in the file. One-line fix, no behavior change to the guard itself. Verified on top of fork/master (efb5a78): - general-server shard 1/30 (8 suites, 38 tests): now runs to completion - packages/db/src/migration-journal-consistency.test.ts: 33/33 pass - scripts/__tests__/check-migration-journal.test.mjs: 8/8 pass
1 parent efb5a78 commit 07968b5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

scripts/run-vitest-stable.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ function runMigrationJournalGuard() {
254254
// suite starts, so the operator sees the offending filename immediately
255255
// instead of hunting through skipped suites.
256256
console.log("\n[test:run] preflight: migration journal consistency");
257-
const result = spawnSync(process.execPath, [path.join(scriptsDir, "check-migration-journal.mjs")], {
257+
const result = spawnSync(process.execPath, [path.join(repoRoot, "scripts", "check-migration-journal.mjs")], {
258258
cwd: repoRoot,
259259
env: process.env,
260260
stdio: "inherit",

0 commit comments

Comments
 (0)