Session 5 of voyage-rebrand (V6). Operator-authorized cross-plugin scope. - git mv plugins/ultraplan-local plugins/voyage (rename detected, history preserved) - .claude-plugin/marketplace.json: voyage entry replaces ultraplan-local - CLAUDE.md: voyage row in plugin list, voyage in design-system consumer list - README.md: bulk rename ultra*-local commands -> trek* commands; ultraplan-local refs -> voyage; type discriminators (type: trekbrief/trekreview); session-title pattern (voyage:<command>:<slug>); v4.0.0 release-note paragraph - plugins/voyage/.claude-plugin/plugin.json: homepage/repository URLs point to monorepo voyage path - plugins/voyage/verify.sh: drop URL whitelist exception (no longer needed) Closes voyage-rebrand. bash plugins/voyage/verify.sh PASS 7/7. npm test 361/361.
42 lines
1.7 KiB
JavaScript
42 lines
1.7 KiB
JavaScript
// tests/lib/main-merge-gate.test.mjs
|
|
// Step 12 (plan-v2) — pin that commands/trekexecute.md Phase 8
|
|
// names the main-merge-gate lifecycle event, the decline + recovery
|
|
// surface, and the always-on gate prose.
|
|
|
|
import { test } from 'node:test';
|
|
import { strict as assert } from 'node:assert';
|
|
import { readFileSync } from 'node:fs';
|
|
import { dirname, join } from 'node:path';
|
|
import { fileURLToPath } from 'node:url';
|
|
|
|
const HERE = dirname(fileURLToPath(import.meta.url));
|
|
const ROOT = join(HERE, '..', '..');
|
|
const CMD = readFileSync(join(ROOT, 'commands/trekexecute.md'), 'utf-8');
|
|
|
|
test('Phase 8 names the main-merge-gate lifecycle event', () => {
|
|
assert.ok(
|
|
CMD.includes('main-merge-gate'),
|
|
'commands/trekexecute.md should emit `main-merge-gate` from Phase 8',
|
|
);
|
|
});
|
|
|
|
test('Phase 8 documents both approved + declined event branches', () => {
|
|
assert.ok(CMD.includes('main-merge-approved'), 'should emit main-merge-approved on confirm');
|
|
assert.ok(CMD.includes('main-merge-declined'), 'should emit main-merge-declined on decline');
|
|
});
|
|
|
|
test('Phase 8 documents the --resume recovery surface for the main-merge gate', () => {
|
|
assert.ok(
|
|
CMD.includes('--resume re-enters'),
|
|
'Phase 8 should document that `--resume re-enters at the gate` after a decline',
|
|
);
|
|
});
|
|
|
|
test('Phase 8 main-merge gate is always-on (regardless of gates_mode)', () => {
|
|
// Main-merge gate is the one boundary that pauses on every run; the prose
|
|
// must say so explicitly so the contract survives copy-edit drift.
|
|
assert.ok(
|
|
/always[\s\S]{0,200}gates_mode|gates_mode[\s\S]{0,200}always|always pauses on every run/.test(CMD),
|
|
'Phase 8 should state main-merge gate is always-on, regardless of gates_mode',
|
|
);
|
|
});
|