Skip to content

<objective> Suite taxonomy gate and requirement-to-test coverage confirmation. Depends on every prior Phase 2 plan so all test files exist before the gate runs.

Purpose: Prove QUAL-02 breadth for Phase 2 and prove no requirement ships without a named test file. Output: The taxonomy test plus a recorded 16/16 coverage result. </objective>

<execution_context> @~/.claude/gsd-core/workflows/execute-plan.md @~/.claude/gsd-core/templates/summary.md </execution_context>

<context> @.planning/PROJECT.md @.planning/ROADMAP.md @.planning/phases/02-policy-state-and-filesystem-lockdown/02-CONTEXT.md @.planning/phases/02-policy-state-and-filesystem-lockdown/02-PATTERNS.md </context>

<tasks>

<task type="auto"> <name>Task 1: Suite taxonomy gate</name> <files>test/quality/suite-taxonomy.test.ts</files> <read_first> - .planning/phases/02-policy-state-and-filesystem-lockdown/02-CONTEXT.md (D-45 full file list and category mapping) - test/integration/podman-gate.test.ts (skip-with-reason convention the taxonomy asserts for integration) </read_first> <action>Write test/quality/suite-taxonomy.test.ts reading category directories with node:fs and asserting each holds at least one star-test.ts file, using the F-5 resolution recorded here: unit covers core, fs, session, audit, lifecycle, contract, and doctor (session, lifecycle, and doctor map to unit, not to new categories); state-machine covers core state-machine; path and symlink covers fs canonicalize and fs toctou; schema rejection covers contract; audit redaction covers audit redaction; integration covers integration with the existing Podman skip carrying a stated reason. Assert the integration files declare their skip reason textually. State in a test title that MCP and ACP contract tests are Phase 5 deliverables per Q-4 and ROADMAP Phase 5 success criterion 5, so their absence here is declared scope, not a gap.</action> <acceptance_criteria> - Taxonomy test fails when any mapped category directory holds zero test files - Integration skip-reason assertion passes against the existing Podman gate - A test title records the Q-4 MCP and ACP deferral to Phase 5 </acceptance_criteria> <verify> <automated>npx tsc -p tsconfig.json && node --test dist/test/quality/suite-taxonomy.test.js</automated> <fails_when>non-zero exit, or the summary shows 0 passed</fails_when> </verify> <done>Taxonomy gate green with the F-5 category map and the Q-4 deferral recorded.</done> </task>

<task type="auto"> <name>Task 2: Requirement-to-test coverage confirmation</name> <files>test/quality/suite-taxonomy.test.ts</files> <read_first> - .planning/phases/02-policy-state-and-filesystem-lockdown/02-CONTEXT.md (D-45: the requirement-to-file map this task checks) </read_first> <action>Extend test/quality/suite-taxonomy.test.ts from Task 1 of this plan with a coverage assertion over the 16 Phase 2 requirement IDs CORE-01, CORE-02, CORE-03, CORE-04, CORE-06, FS-01, FS-02, FS-03, FS-04, FS-05, RT-07, TOOL-01, TOOL-02, AUD-01, AUD-02, QUAL-02: for each ID, at least one D-45 test file under test/ contains the ID string (every plan's tests cite their IDs in test titles, so the check is textual and stable). Report any uncovered ID by name; the suite fails while the list is non-empty. Record the final REQ coverage line of 16/16 in the plan summary.</action> <acceptance_criteria> - All 16 IDs found in at least one D-45 test file each - Any missing ID fails the suite naming the ID - QUAL-02 coverage is claimed only through the transport-neutral tool schema contract cases, never through fake MCP or ACP tests </acceptance_criteria> <verify> <automated>npx tsc -p tsconfig.json && node --test dist/test/quality/suite-taxonomy.test.js; for id in CORE-01 CORE-02 CORE-03 CORE-04 CORE-06 FS-01 FS-02 FS-03 FS-04 FS-05 RT-07 TOOL-01 TOOL-02 AUD-01 AUD-02 QUAL-02; do grep -rq "$id" test/ || echo "MISSING:$id"; done</automated> <fails_when>non-zero exit, 0 passed in the summary, or any MISSING line printed</fails_when> </verify> <done>Coverage confirmation green at 16/16 with no fake transport tests.</done> </task>

</tasks>

<threat_model>

Trust Boundaries ​

BoundaryDescription
test suite -> release gateA passing taxonomy is trusted as breadth evidence; a false pass ships untested surface

STRIDE Threat Register ​

Threat IDCategoryComponentSeverityDispositionMitigation Plan
T-02-13E (Elevation of Privilege)test/quality/suite-taxonomy.test.tslowmitigateGate counts real star-test.ts files per directory; an empty category fails instead of passing silently
T-02-14R (Repudiation)QUAL-02 MCP and ACP clauselowacceptNo MCP or ACP surface exists until Phase 5, so no contract test can be truthful here; the deferral is stated in the suite and in this plan per Q-4, and ROADMAP Phase 5 success criterion 5 owns the clause
</threat_model>

<verification> npx tsc -p tsconfig.json && node --test dist/test/quality/suite-taxonomy.test.js; npm run lint; npm run typecheck. </verification>

<success_criteria> Taxonomy gate and 16/16 requirement coverage both green, Q-4 deferral stated, lint and typecheck clean. </success_criteria>

<output> Create .planning/phases/02-policy-state-and-filesystem-lockdown/02-06-SUMMARY.md when done </output>

Artifacts this phase produces ​

  • test/quality/suite-taxonomy.test.ts (QUAL-02: category breadth gate with the F-5 map, integration skip-reason assertion, 16-ID coverage assertion, Q-4 MCP and ACP deferral statement; the transport-neutral contract clause is covered by test/contract/tool-input-gate.test.ts from plan 02-04, and no MCP or ACP tests are written in Phase 2)

AGPL-3.0-only. Copyright (C) 2026 Spectrum Web Co/swcstudiospace.