You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: test coverage gate + plan completion audit + auto-verification (v0.11.13.0) (garrytan#428)
* feat: test coverage gate + plan completion audit + auto-verification
Three new gates in /ship and /review:
1. Test coverage gate: configurable thresholds (60%/80% default), hard stop
below minimum with user override
2. Plan completion audit: discovers plan file, extracts actionable items,
cross-references against diff, gates on NOT DONE items
3. Auto-verification: invokes /qa-only inline with plan's verification
section, conditional on localhost reachability
Also: coverage warning in /review, plan completion data in /retro,
shared plan file discovery helper (DRY), ship metrics logging.
* chore: regenerate SKILL.md files
* chore: bump version and changelog (v0.11.13.0)
Co-Authored-By: Claude Opus 4.6 <[email protected]>
---------
Co-authored-by: Claude Opus 4.6 <[email protected]>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+15Lines changed: 15 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,20 @@
1
1
# Changelog
2
2
3
+
## [0.11.18.0] - 2026-03-24 — Ship With Teeth
4
+
5
+
`/ship` and `/review` now actually enforce the quality gates they've been talking about. Coverage audit becomes a real gate (not just a diagram), plan completion gets verified against the diff, and verification steps from your plan run automatically.
6
+
7
+
### Added
8
+
9
+
-**Test coverage gate in /ship.** AI-assessed coverage below 60% is a hard stop. 60-79% gets a prompt. 80%+ passes. Thresholds are configurable per-project via `## Test Coverage` in CLAUDE.md.
10
+
-**Coverage warning in /review.** Low coverage is now flagged prominently before you reach the /ship gate, so you can write tests early.
11
+
-**Plan completion audit.** /ship reads your plan file, extracts every actionable item, cross-references against the diff, and shows you a DONE/NOT DONE/PARTIAL/CHANGED checklist. Missing items are a shipping blocker (with override).
12
+
-**Plan-aware scope drift detection.** /review's scope drift check now reads the plan file too — not just TODOS.md and PR description.
13
+
-**Auto-verification via /qa-only.** /ship reads your plan's verification section and runs /qa-only inline to test it — if a dev server is running on localhost. No server, no problem — it skips gracefully.
14
+
-**Shared plan file discovery.** Conversation context first, content-based grep fallback second. Used by plan completion, plan review reports, and verification.
15
+
-**Ship metrics logging.** Coverage %, plan completion ratio, and verification results are logged to review JSONL for /retro to track trends.
16
+
-**Plan completion in /retro.** Weekly retros now show plan completion rates across shipped branches.
Copy file name to clipboardExpand all lines: review/SKILL.md
+129-1Lines changed: 129 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -322,7 +322,120 @@ Before reviewing code quality, check: **did they build what was requested — no
322
322
**If no PR exists:** rely on commit messages and TODOS.md for stated intent — this is the common case since /review runs before /ship creates the PR.
323
323
2. Identify the **stated intent** — what was this branch supposed to accomplish?
324
324
3. Run `git diff origin/<base>...HEAD --stat` and compare the files changed against the stated intent.
325
-
4. Evaluate with skepticism:
325
+
326
+
### Plan File Discovery
327
+
328
+
1.**Conversation context (primary):** Check if there is an active plan file in this conversation — Claude Code system messages include plan file paths when in plan mode. Look for references like `~/.claude/plans/*.md` in system messages. If found, use it directly — this is the most reliable signal.
329
+
330
+
2.**Content-based search (fallback):** If no plan file is referenced in conversation context, search by content:
3.**Validation:** If a plan file was found via content-based search (not conversation context), read the first 20 lines and verify it is relevant to the current branch's work. If it appears to be from a different project or feature, treat as "no plan file found."
345
+
346
+
**Error handling:**
347
+
- No plan file found → skip with "No plan file detected — skipping."
348
+
- Plan file found but unreadable (permissions, encoding) → skip with "Plan file found but unreadable — skipping."
349
+
350
+
### Actionable Item Extraction
351
+
352
+
Read the plan file. Extract every actionable item — anything that describes work to be done. Look for:
- Explicitly deferred items ("Future:", "Out of scope:", "NOT in scope:", "P2:", "P3:", "P4:")
366
+
- CEO Review Decisions sections (these record choices, not work items)
367
+
368
+
**Cap:** Extract at most 50 items. If the plan has more, note: "Showing top 50 of N plan items — full list in plan file."
369
+
370
+
**No items found:** If the plan contains no extractable actionable items, skip with: "Plan file contains no actionable items — skipping completion audit."
371
+
372
+
For each item, note:
373
+
- The item text (verbatim or concise summary)
374
+
- Its category: CODE | TEST | MIGRATION | CONFIG | DOCS
375
+
376
+
### Cross-Reference Against Diff
377
+
378
+
Run `git diff origin/<base>...HEAD` and `git log origin/<base>..HEAD --oneline` to understand what was implemented.
379
+
380
+
For each extracted plan item, check the diff and classify:
381
+
382
+
-**DONE** — Clear evidence in the diff that this item was implemented. Cite the specific file(s) changed.
383
+
-**PARTIAL** — Some work toward this item exists in the diff but it's incomplete (e.g., model created but controller missing, function exists but edge cases not handled).
384
+
-**NOT DONE** — No evidence in the diff that this item was addressed.
385
+
-**CHANGED** — The item was implemented using a different approach than the plan described, but the same goal is achieved. Note the difference.
386
+
387
+
**Be conservative with DONE** — require clear evidence in the diff. A file being touched is not enough; the specific functionality described must be present.
388
+
**Be generous with CHANGED** — if the goal is met by different means, that counts as addressed.
Delivered: <1-line summary of what the diff actually does>
431
+
Plan items: N DONE, M PARTIAL, K NOT DONE
432
+
[If NOT DONE: list each missing item]
433
+
[If scope creep: list each out-of-scope change not in the plan]
434
+
```
435
+
436
+
**No plan file found:** Fall back to existing scope drift behavior (check TODOS.md and PR description only).
437
+
438
+
4. Evaluate with skepticism (incorporating plan completion results if available):
326
439
327
440
**SCOPE CREEP detection:**
328
441
- Files changed that are unrelated to the stated intent
@@ -631,6 +744,21 @@ If no test framework detected → include gaps as INFORMATIONAL findings only, n
631
744
632
745
**Diff is test-only changes:** Skip Step 4.75 entirely: "No new application code paths to audit."
633
746
747
+
### Coverage Warning
748
+
749
+
After producing the coverage diagram, check the coverage percentage. Read CLAUDE.md for a `## Test Coverage` section with a `Minimum:` field. If not found, use default: 60%.
750
+
751
+
If coverage is below the minimum threshold, output a prominent warning **before** the regular review findings:
This is INFORMATIONAL — does not block /review. But it makes low coverage visible early so the developer can address it before reaching the /ship coverage gate.
759
+
760
+
If coverage percentage cannot be determined, skip the warning silently.
761
+
634
762
This step subsumes the "Test Gaps" category from Pass 2 — do not duplicate findings between the checklist Test Gaps item and this coverage diagram. Include any coverage gaps alongside the findings from Step 4 and Step 4.5. They follow the same Fix-First flow — gaps are INFORMATIONAL findings.
0 commit comments