test: wire the orphaned scripts/ test suite to a vitest runner
scripts/*.test.mjs had NO runner: scripts/ is not a workspace package (turbo never reaches it) and no CI step invoked node --test, so all 16 files — 241 assertions over conformance, coverage, compliance, library-decisions and work tooling — were dead. Wire them via a root vitest.scripts.config.mjs + 'pnpm test:scripts' + a CI validate step, converting the node:test imports to vitest (node:assert kept, same pattern as the generators' release-please-utils conversion). First-run fallout fixed: the work fixtures missed the epics/ subdir buildState walks, the expected epic shape lacked the prd field, the CLI dispatch test assumed a ready task exists, and the state-sync-guard smoke held an unused binding. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -8,9 +8,10 @@ const GUARD = path.join(__dirname, "state-sync-guard.mjs");
|
|||||||
|
|
||||||
describe("state-sync-guard smoke", () => {
|
describe("state-sync-guard smoke", () => {
|
||||||
it("exits 0 when run against the repo's current state (since main is in sync)", () => {
|
it("exits 0 when run against the repo's current state (since main is in sync)", () => {
|
||||||
// Run the guard; if main's _state.json drifts, this test will fail and tell us.
|
// Run the guard; if main's _state.json drifts, execSync throws (non-zero
|
||||||
const result = execSync(`node "${GUARD}"`, { encoding: "utf8" });
|
// exit) and this test fails with the guard's output.
|
||||||
// No assertion on output; the exit code is 0 if we got here without throwing.
|
expect(() =>
|
||||||
expect(true).toBe(true);
|
execSync(`node "${GUARD}"`, { encoding: "utf8" }),
|
||||||
|
).not.toThrow();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user