docs(ultraplan-local): Handover 7 § Lifecycle (SC-5 stale-file principle)
Step 11 of v3.4.1 plan. Adds the lifecycle subsection to Handover 7 documenting: - Producer/consumer arbeidsdeling (executor + helper write; ultracontinue reads; pre-compact-flush refreshes only) - Stale-file principle: status==='completed' state files SHOULD be removed via /ultracontinue-local --cleanup --confirm (operator-invoked, no auto-cleanup, no force flag) - Frontmatter contract for NEXT-SESSION-PROMPT.local.md: producers MUST write produced_by + produced_at (ISO-8601); files without frontmatter are tolerated (warning, not error) for backwards compatibility - Idempotency: --cleanup --confirm is safe to re-run; partial state reported but never auto-recovered Adds 3 doc-consistency pins: - next-session-prompt-validator CLI shim - Handover 7 § Lifecycle subsection present - Handover 7 § Lifecycle names --cleanup + produced_by contract 358 -> 361 tests, all green. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
parent
9fa83bdf2f
commit
1da4f3fe30
2 changed files with 61 additions and 0 deletions
|
|
@ -140,6 +140,43 @@ test('session-state-validator has CLI shim', () => {
|
|||
);
|
||||
});
|
||||
|
||||
test('next-session-prompt-validator has CLI shim', () => {
|
||||
const text = read('lib/validators/next-session-prompt-validator.mjs');
|
||||
assert.ok(
|
||||
text.includes('import.meta.url === '),
|
||||
'lib/validators/next-session-prompt-validator.mjs should expose the standard CLI shim ' +
|
||||
'(if (import.meta.url === `file://${process.argv[1]}`)) so /ultracontinue Phase 1.5 can call it from Bash',
|
||||
);
|
||||
});
|
||||
|
||||
test('HANDOVER-CONTRACTS.md Handover 7 documents § Lifecycle subsection', () => {
|
||||
const text = read('docs/HANDOVER-CONTRACTS.md');
|
||||
const h7Start = text.indexOf('## Handover 7');
|
||||
assert.ok(h7Start >= 0, 'Handover 7 heading missing');
|
||||
const h7End = text.indexOf('## Stability summary', h7Start);
|
||||
assert.ok(h7End > h7Start, 'Stability summary heading missing — could not bound Handover 7');
|
||||
const h7 = text.slice(h7Start, h7End);
|
||||
assert.ok(
|
||||
h7.includes('Lifecycle'),
|
||||
'Handover 7 section should include a § Lifecycle subsection (SC-5 stale-file principle)',
|
||||
);
|
||||
});
|
||||
|
||||
test('HANDOVER-CONTRACTS.md Handover 7 § Lifecycle names --cleanup and produced_by contract', () => {
|
||||
const text = read('docs/HANDOVER-CONTRACTS.md');
|
||||
const h7Start = text.indexOf('## Handover 7');
|
||||
const h7End = text.indexOf('## Stability summary', h7Start);
|
||||
const h7 = text.slice(h7Start, h7End);
|
||||
assert.ok(
|
||||
h7.includes('--cleanup'),
|
||||
'Handover 7 § Lifecycle should mention --cleanup as the operator-invoked stale-file remover',
|
||||
);
|
||||
assert.ok(
|
||||
h7.includes('produced_by'),
|
||||
'Handover 7 § Lifecycle should document the produced_by frontmatter contract for NEXT-SESSION-PROMPT.local.md',
|
||||
);
|
||||
});
|
||||
|
||||
test('CLAUDE.md mentions /ultracontinue-local command', () => {
|
||||
const md = read('CLAUDE.md');
|
||||
assert.ok(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue