|
990 | 990 | - **Expected Behavior:** Each file mentions the broker concept, the preflight CLI, the gate, and the `/why` toggle. |
991 | 991 | - **Confidence:** 1.0 |
992 | 992 |
|
| 993 | +## TEST-091. Orchestrator.run_task Returns a Structured TaskResult |
| 994 | +- **ID:** TEST-091 |
| 995 | +- **Title:** Orchestrator.run_task Returns a Structured TaskResult |
| 996 | +- **Description:** `orchestrator.run_task` must return a `TaskResult` instance whose attributes include `equilibrium`, `confidence`, `summary`, `files_changed`, and `test_results`. The REPL source must consume that result inside the executor closure (`result.equilibrium`, `result.confidence`) rather than computing equilibrium from `bool(summary)`. |
| 997 | +- **Requirement ID:** REQ-091 |
| 998 | +- **Type:** unit |
| 999 | +- **Verification Method:** pytest |
| 1000 | +- **Input:** orchestrator module + REPL source |
| 1001 | +- **Expected Behavior:** TaskResult dataclass exposes the required fields; REPL source references `result.equilibrium` and `result.confidence`. |
| 1002 | +- **Confidence:** 1.0 |
| 1003 | + |
| 1004 | +## TEST-092. specsmith preflight CLI Returns Decision-Specific Exit Codes |
| 1005 | +- **ID:** TEST-092 |
| 1006 | +- **Title:** specsmith preflight CLI Returns Decision-Specific Exit Codes |
| 1007 | +- **Description:** Invoking `specsmith preflight` over a tmp project must exit 0 for `accepted` decisions, 2 for `needs_clarification`, and 3 for `blocked`/`rejected`. The JSON payload must continue to be emitted on stdout regardless of exit code. |
| 1008 | +- **Requirement ID:** REQ-092 |
| 1009 | +- **Type:** unit |
| 1010 | +- **Verification Method:** pytest |
| 1011 | +- **Input:** click.testing.CliRunner over isolated tmp_path |
| 1012 | +- **Expected Behavior:** Exit code matches the decision; JSON parses on stdout for both 0 and 2 exits. |
| 1013 | +- **Confidence:** 1.0 |
| 1014 | + |
| 1015 | +## TEST-093. Accepted preflight Records a Ledger Event |
| 1016 | +- **ID:** TEST-093 |
| 1017 | +- **Title:** Accepted preflight Records a Ledger Event |
| 1018 | +- **Description:** When the preflight decision is `accepted` and `LEDGER.md` exists in the tmp project root, invoking the CLI must append a new ledger entry tagged with `REQ-085` and the matched `requirement_ids`. When the decision is `needs_clarification`, the ledger must not gain an entry. |
| 1019 | +- **Requirement ID:** REQ-093 |
| 1020 | +- **Type:** unit |
| 1021 | +- **Verification Method:** pytest |
| 1022 | +- **Input:** click.testing.CliRunner with seeded LEDGER.md |
| 1023 | +- **Expected Behavior:** LEDGER.md grows on accept; LEDGER.md unchanged on needs_clarification. |
| 1024 | +- **Confidence:** 1.0 |
| 1025 | + |
| 1026 | +## TEST-094. /why Surfaces Post-Run Governance Block in REPL |
| 1027 | +- **ID:** TEST-094 |
| 1028 | +- **Title:** /why Surfaces Post-Run Governance Block in REPL |
| 1029 | +- **Description:** Inspecting the REPL source must show a `[/why]` post-run block guarded by `verbose_governance` after `execute_with_governance` returns; the block must reference `work_item_id`, `requirement_ids`, `test_case_ids`, `confidence`, and `equilibrium`. |
| 1030 | +- **Requirement ID:** REQ-094 |
| 1031 | +- **Type:** unit |
| 1032 | +- **Verification Method:** pytest |
| 1033 | +- **Input:** repl module source |
| 1034 | +- **Expected Behavior:** Source contains a `[/why]` block guarded by verbose_governance and referencing the required keys. |
| 1035 | +- **Confidence:** 1.0 |
| 1036 | + |
| 1037 | +## TEST-095. Nexus Live Smoke Evidence Captured |
| 1038 | +- **ID:** TEST-095 |
| 1039 | +- **Title:** Nexus Live Smoke Evidence Captured |
| 1040 | +- **Description:** `.specsmith/runs/WI-NEXUS-011/logs.txt` must exist and document either a successful live smoke (`ok: true`) or an honest reason the live container could not be reached. |
| 1041 | +- **Requirement ID:** REQ-095 |
| 1042 | +- **Type:** unit |
| 1043 | +- **Verification Method:** pytest |
| 1044 | +- **Input:** .specsmith/runs/WI-NEXUS-011/logs.txt |
| 1045 | +- **Expected Behavior:** Log file present and non-empty; mentions either ok=true/false from the smoke script. |
| 1046 | +- **Confidence:** 1.0 |
| 1047 | + |
0 commit comments