diff --git a/tests/prose/cases/discovery-commits-new-epic/case.json b/tests/prose/cases/discovery-commits-new-epic/case.json index c5ba46ed1..3deb26e77 100644 --- a/tests/prose/cases/discovery-commits-new-epic/case.json +++ b/tests/prose/cases/discovery-commits-new-epic/case.json @@ -11,7 +11,10 @@ "skills/workflow-discovery/references/shape-and-confirm.md", "skills/workflow-discovery/references/confirm-trigger.md", "skills/workflow-discovery/references/name-resolution.md", - "skills/workflow-discovery/references/template.md" + "skills/workflow-discovery/references/template.md", + "skills/workflow-shared/references/casing-conventions.md", + "skills/workflow-discovery/references/detection-core.md", + "skills/workflow-discovery/references/resume-detection.md" ], "answers": [ "e — start a new epic", diff --git a/tests/prose/cases/discovery-commits-new-feature/case.json b/tests/prose/cases/discovery-commits-new-feature/case.json index 36231b11b..e623d978d 100644 --- a/tests/prose/cases/discovery-commits-new-feature/case.json +++ b/tests/prose/cases/discovery-commits-new-feature/case.json @@ -11,7 +11,9 @@ "skills/workflow-discovery/references/shape-and-confirm.md", "skills/workflow-discovery/references/confirm-trigger.md", "skills/workflow-discovery/references/name-resolution.md", - "skills/workflow-discovery/references/template.md" + "skills/workflow-discovery/references/template.md", + "skills/workflow-shared/references/casing-conventions.md", + "skills/workflow-discovery/references/detection-core.md" ], "answers": [ "f — start a new feature", diff --git a/tests/prose/cases/discussion-entry-seeds-from-carrier/case.json b/tests/prose/cases/discussion-entry-seeds-from-carrier/case.json index b0f907864..d18feea4d 100644 --- a/tests/prose/cases/discussion-entry-seeds-from-carrier/case.json +++ b/tests/prose/cases/discussion-entry-seeds-from-carrier/case.json @@ -1,9 +1,10 @@ { - "origin": "feature mainline \u2014 single-phase work seeds from its durable carrier", + "origin": "feature mainline — single-phase work seeds from its durable carrier", "entry": "workflow-discussion-entry", "files": [ "skills/workflow-discussion-entry/SKILL.md", - "skills/workflow-shared/references/ensure-discovery-item.md" + "skills/workflow-shared/references/ensure-discovery-item.md", + "skills/workflow-discussion-entry/references/invoke-skill.md" ], "invariants": { "calls_include": [ diff --git a/tests/prose/cases/implementation-picks-first-task/case.json b/tests/prose/cases/implementation-picks-first-task/case.json index f5c58f453..29656560e 100644 --- a/tests/prose/cases/implementation-picks-first-task/case.json +++ b/tests/prose/cases/implementation-picks-first-task/case.json @@ -1,15 +1,16 @@ { - "origin": "feature mainline \u2014 entry through resume detection to the first task", + "origin": "feature mainline — entry through resume detection to the first task", "entry": "workflow-implementation-entry", "files": [ "skills/workflow-implementation-entry/SKILL.md", "skills/workflow-implementation-entry/references/validate-phase.md", "skills/workflow-implementation-entry/references/validate-dependencies.md", "skills/workflow-implementation-process/SKILL.md", - "skills/workflow-implementation-process/references/environment-setup.md" + "skills/workflow-implementation-process/references/environment-setup.md", + "skills/workflow-implementation-entry/references/invoke-skill.md" ], "answers": [ - "none \u2014 no special setup is needed" + "none — no special setup is needed" ], "invariants": { "engine_before_write": true, diff --git a/tests/prose/cases/investigation-entry-seeds-from-carrier/case.json b/tests/prose/cases/investigation-entry-seeds-from-carrier/case.json index d11bcfca0..080b022f7 100644 --- a/tests/prose/cases/investigation-entry-seeds-from-carrier/case.json +++ b/tests/prose/cases/investigation-entry-seeds-from-carrier/case.json @@ -1,5 +1,5 @@ { - "origin": "bugfix mainline \u2014 a bug shaped in discovery is never re-interrogated", + "origin": "bugfix mainline — a bug shaped in discovery is never re-interrogated", "entry": "workflow-investigation-entry", "files": [ "skills/workflow-investigation-entry/SKILL.md", diff --git a/tests/prose/cases/investigation-initialises-the-phase/act.md b/tests/prose/cases/investigation-initialises-the-phase/act.md new file mode 100644 index 000000000..3de6eb704 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/act.md @@ -0,0 +1,4 @@ +Execute skills/workflow-investigation-entry/SKILL.md with arguments +$0=bugfix, $1=crash-fix, and continue into the processing skill it hands +off to. Stop once the phase has been initialised and the prose turns to +gathering symptoms from the user — do not gather them, and ask nothing. diff --git a/tests/prose/cases/investigation-initialises-the-phase/assert.md b/tests/prose/cases/investigation-initialises-the-phase/assert.md new file mode 100644 index 000000000..480d70c96 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/assert.md @@ -0,0 +1,31 @@ +The prose should have taken this path: + +1. the entry resolves the topic to the work unit, finds no investigation + recorded, and hands off — the entry itself creates nothing +2. the processing skill checks for an existing investigation file before + anything else; there is none, so this is a fresh start and no resume + choice is put to the user +3. initialisation reads the work's seed before writing, so the phase + opens from the origin rather than from an empty page +4. the investigation file is created from the template, and the symptoms + the discovery carrier already recorded are placed into it — the user + is not asked to repeat what they have already said +5. the phase is registered through the engine and the file committed, + and only then does the prose turn to gathering further symptoms + +Further claims: + +- the walk stops with the symptom interview unstarted: the prose reaches + the point of asking and the case ends there, so no question is put + +EXPECTED WORLD — from a work unit whose investigation had not begun: + +- an investigation file at `.workflows/crash-fix/investigation/crash-fix.md`, + carrying the template's section structure — Symptoms, Analysis, Fix + Direction, Notes +- its Symptoms section seeded from what discovery already captured about + the checkout crash, not left as template placeholders +- its Analysis and Fix Direction sections still unwritten: nothing has + been traced or decided, and the walk stops before either begins +- the investigation registered as in progress on the work unit +- no other phase touched, and no second work unit diff --git a/tests/prose/cases/investigation-initialises-the-phase/case.json b/tests/prose/cases/investigation-initialises-the-phase/case.json new file mode 100644 index 000000000..55f25e915 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/case.json @@ -0,0 +1,31 @@ +{ + "origin": "the first case to walk past a handoff into a processing skill — investigation's initialisation, where the phase's artifact first exists on disk", + "entry": "workflow-investigation-entry", + "world": "claims", + "files": [ + "skills/workflow-investigation-entry/SKILL.md", + "skills/workflow-investigation-entry/references/invoke-skill.md", + "skills/workflow-investigation-process/SKILL.md", + "skills/workflow-investigation-process/references/initialize-investigation.md", + "skills/workflow-investigation-process/references/template.md", + "skills/workflow-shared/references/seed-context.md", + "skills/workflow-knowledge/references/knowledge-usage.md" + ], + "invariants": { + "engine_before_write": true, + "calls_include": [ + "manifest get crash-fix.investigation.crash-fix status", + "manifest get crash-fix seeds", + "topic start crash-fix investigation crash-fix" + ], + "calls_in_order": [ + "manifest get crash-fix.investigation.crash-fix status", + "topic start crash-fix investigation crash-fix" + ], + "calls_exclude": [ + "topic complete", + "knowledge.cjs index", + "topic reopen" + ] + } +} diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture-state.cjs b/tests/prose/cases/investigation-initialises-the-phase/fixture-state.cjs new file mode 100644 index 000000000..88039b9f7 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture-state.cjs @@ -0,0 +1,14 @@ +'use strict'; + +// The same starting world as the entry case: the bug is captured and the +// investigation has not begun. This case is what happens next — the walk +// carries on past the handoff the entry case stops at. + +const m = require('../../mainlines/bugfix.cjs'); + +module.exports = { + build(h) { + m.init(h); + m.create(h); + }, +}; diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture.md b/tests/prose/cases/investigation-initialises-the-phase/fixture.md new file mode 100644 index 000000000..ec8bf31b4 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture.md @@ -0,0 +1,7 @@ +A bugfix shaped in discovery and routed to investigation. The work unit +exists with its session log; nothing in the investigation phase has been +started, and no investigation file exists. + +The bridge has just written its plan file and the context was cleared — +this session opens cold at the entry skill, carrying nothing but the two +arguments and whatever is on disk. diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.claude/settings.json b/tests/prose/cases/investigation-initialises-the-phase/fixture/.claude/settings.json new file mode 100644 index 000000000..ae019ede5 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.claude/settings.json @@ -0,0 +1,9 @@ +{ + "showClearContextOnPlanAccept": true, + "permissions": { + "allow": [ + "Edit(.workflows/**)", + "Bash(mv .workflows/:*)" + ] + } +} diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.recipe-hash b/tests/prose/cases/investigation-initialises-the-phase/fixture/.recipe-hash new file mode 100644 index 000000000..5796f59d5 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.recipe-hash @@ -0,0 +1 @@ +418aebad0817dc3bca89f861fd52682d4c1327da18ca5869d7b68eb6f38fbe4b diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/.state/migrations b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/.state/migrations new file mode 100644 index 000000000..3c7162acc --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/.state/migrations @@ -0,0 +1,52 @@ +001 +002 +003 +004 +005 +006 +007 +008 +009 +010 +011 +012 +013 +014 +015 +016 +017 +018 +019 +020 +021 +022 +023 +024 +025 +026 +027 +028 +029 +030 +031 +032 +033 +034 +035 +036 +037 +038 +039 +040 +041 +042 +043 +044 +045 +046 +047 +048 +049 +050 +051 +052 diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/_gitignore.fixture b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/_gitignore.fixture new file mode 100644 index 000000000..779cbf28a --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/_gitignore.fixture @@ -0,0 +1,2 @@ +.cache/ +.manifest.json.*.tmp diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/crash-fix/discovery/sessions/session-001.md b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/crash-fix/discovery/sessions/session-001.md new file mode 100644 index 000000000..6dc56d4e3 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/crash-fix/discovery/sessions/session-001.md @@ -0,0 +1,40 @@ +# Discovery Session 001 + +Date: 2026-01-01 +Work unit: crash-fix + +## Description (as of session) + +Checkout crashes when an order has no shipping address. + +## Seed + +(none) + +## Imports + +(none) + +## Map State at Start + +(n/a — single-topic work) + +## Exploration + +Reported by two users this week: the checkout page 500s at the +payment step for orders with no shipping address. Reproducible on +staging with a digital-only basket. No error surfaces to the user — +the page just fails. Confirmed as a bugfix; no design question here, +so it routes straight to investigation. + +## Edits + +(none) + +## Topics Identified + +(none) + +## Conclusion + +(none) diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/crash-fix/manifest.json b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/crash-fix/manifest.json new file mode 100644 index 000000000..eaaa56199 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/crash-fix/manifest.json @@ -0,0 +1,8 @@ +{ + "name": "crash-fix", + "work_type": "bugfix", + "status": "in-progress", + "created": "2026-01-01", + "description": "Checkout crashes when an order has no shipping address", + "phases": {} +} diff --git a/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/manifest.json b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/manifest.json new file mode 100644 index 000000000..1cd498ed5 --- /dev/null +++ b/tests/prose/cases/investigation-initialises-the-phase/fixture/.workflows/manifest.json @@ -0,0 +1,7 @@ +{ + "work_units": { + "crash-fix": { + "work_type": "bugfix" + } + } +} diff --git a/tests/prose/cases/planning-entry-asks-for-late-context/case.json b/tests/prose/cases/planning-entry-asks-for-late-context/case.json index 072803bfd..9753fd5ec 100644 --- a/tests/prose/cases/planning-entry-asks-for-late-context/case.json +++ b/tests/prose/cases/planning-entry-asks-for-late-context/case.json @@ -1,14 +1,15 @@ { - "origin": "feature mainline \u2014 planning offers a last chance to add context", + "origin": "feature mainline — planning offers a last chance to add context", "entry": "workflow-planning-entry", "files": [ "skills/workflow-planning-entry/SKILL.md", "skills/workflow-planning-entry/references/validate-spec.md", "skills/workflow-planning-entry/references/validate-phase.md", - "skills/workflow-planning-entry/references/cross-cutting-context.md" + "skills/workflow-planning-entry/references/cross-cutting-context.md", + "skills/workflow-planning-entry/references/invoke-skill.md" ], "answers": [ - "continue \u2014 nothing has changed since the specification" + "continue — nothing has changed since the specification" ], "invariants": { "calls_include": [ diff --git a/tests/prose/cases/review-entry-fresh/case.json b/tests/prose/cases/review-entry-fresh/case.json index 1bac663c7..f67fedaf9 100644 --- a/tests/prose/cases/review-entry-fresh/case.json +++ b/tests/prose/cases/review-entry-fresh/case.json @@ -1,9 +1,10 @@ { - "origin": "feature mainline \u2014 review refuses to start until delivery is complete", + "origin": "feature mainline — review refuses to start until delivery is complete", "entry": "workflow-review-entry", "files": [ "skills/workflow-review-entry/SKILL.md", - "skills/workflow-review-entry/references/validate-phase.md" + "skills/workflow-review-entry/references/validate-phase.md", + "skills/workflow-review-entry/references/invoke-skill.md" ], "invariants": { "calls_include": [ diff --git a/tests/prose/cases/spec-entry-from-discussion/case.json b/tests/prose/cases/spec-entry-from-discussion/case.json index bbae6fa2a..6262114ea 100644 --- a/tests/prose/cases/spec-entry-from-discussion/case.json +++ b/tests/prose/cases/spec-entry-from-discussion/case.json @@ -1,5 +1,5 @@ { - "origin": "feature mainline \u2014 a feature's spec draws on its discussion", + "origin": "feature mainline — a feature's spec draws on its discussion", "entry": "workflow-specification-entry", "files": [ "skills/workflow-specification-entry/SKILL.md", diff --git a/tests/prose/cases/spec-entry-from-investigation/case.json b/tests/prose/cases/spec-entry-from-investigation/case.json index a2fd8f96b..311973478 100644 --- a/tests/prose/cases/spec-entry-from-investigation/case.json +++ b/tests/prose/cases/spec-entry-from-investigation/case.json @@ -1,10 +1,11 @@ { - "origin": "bugfix mainline \u2014 the same entry skill, sourced from an investigation", + "origin": "bugfix mainline — the same entry skill, sourced from an investigation", "entry": "workflow-specification-entry", "files": [ "skills/workflow-specification-entry/SKILL.md", "skills/workflow-specification-entry/references/validate-source.md", - "skills/workflow-specification-entry/references/invoke-skill.md" + "skills/workflow-specification-entry/references/invoke-skill.md", + "skills/workflow-specification-entry/references/validate-phase.md" ], "invariants": { "calls_include": [ diff --git a/tests/prose/cases/start-lists-active-work/case.json b/tests/prose/cases/start-lists-active-work/case.json index a588da9ab..c3331237e 100644 --- a/tests/prose/cases/start-lists-active-work/case.json +++ b/tests/prose/cases/start-lists-active-work/case.json @@ -1,8 +1,10 @@ { - "origin": "feature mainline \u2014 the entry skill surfaces work without touching it", + "origin": "feature mainline — the entry skill surfaces work without touching it", "entry": "workflow-start", "files": [ - "skills/workflow-start/SKILL.md" + "skills/workflow-start/SKILL.md", + "skills/workflow-shared/references/casing-conventions.md", + "skills/workflow-start/references/active-work.md" ], "invariants": { "calls_include": [