Repository navigation
Add check_placeholders cases for conditionals, section bounds, and trimming - #155
Conversation
…imming Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Self-review rubric (scored against CI run 37901826523 and the diff):
Judgment flag: Summary: no blocking findings. Merge-ready once the review poll completes. This comment was drafted during a Gardener session (https://github.com/Stephenson-Software/gardener). drafted by Claude on behalf of Daniel Stephenson |
There was a problem hiding this comment.
🟢 Approval recommended
The focused tests accurately characterize the existing implementation and introduce no unresolved issues.
0 open findings
What changed in this PR
Adds regression coverage for check_placeholders without changing production behavior.
Changes:
- Adds six fixture cases covering conditionals, section boundaries, sorting, whitespace, and unused rows.
- Confirms existing one-way template-to-table validation behavior.
| File | Description |
|---|---|
tests/test_check_docs.py |
Expands check_placeholders unit-test coverage. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Summary
Stage B (unit-test expansion) cycle targeting
check_placeholdersinscripts/check_docs.py— the check that enforces CLAUDE.md's "every{{placeholder}}has a Step 4 row" rule. Six fixture cases are added toCheckPlaceholdersTests, each characterizing current behavior; no production code is changed.{{#if FLAG}}errors — the conditional-flag failure branch had only a happy-path case. The error names{{FLAG}}and never reports the closing{{/if}}.###heading still leaves the placeholder reported missing.###heading, the table is read to end of file.{{ALPHA}}, {{ZED}}).{{ NAME }},{{#if FLAG }}, and{{ /if }}are trimmed before matching.check_docs.pydocstring and CLAUDE.md state only the forward direction. A probe of the live file found no genuinely unused row today; the only row with no template use is thepath/to/fileexample row in theDOC_SOURCES_TABLEguidance (line 651), so a naive reverse check would false-positive on it.No tracking issue — gap found during triage (Phase 2 Stage B: the failure branches of
check_placeholdershad no fixture case).Research grounding
RESEARCH.md §3 — regression guards on behavior-bearing code. No template or phase definition is changed, so no Implementations entry applies.
Doc sync check
No docs, template, Step, or placeholder changed.
python3 scripts/check_docs.pypasses.Test plan
python3 -m unittest discover -s tests -v— Ran 19 tests, OK (13 before this change)python3 scripts/check_docs.py— "Doc consistency check passed."/create-dev-loopbehavioral run — not applicable (test-only change; nothing the generated skill receives is touched)Skipped issues
This cycle was spent on test expansion rather than the open backlog, for the same reasons recorded in #153:
CLAUDE.md, which is harness-blocked in this loop and needs separate maintainer authorization.template-rule) — each adds a new rule to the template body. Nothing automated tests the template body, and a headless session cannot do the real/create-dev-loopvalidation run. Phase 5: compress the review wait for a single autonomous run with no reviewer assigned or requested #150 is partly covered by Name the Copilot reviewer @copilot; skip the review poll when no reviewer was requested #154's "Reviewer addition fails" change, but its "no reviewer configured" case is still open.This PR description was drafted during a Gardener session (https://github.com/Stephenson-Software/gardener).
🤖 Generated with Claude Code
drafted by Claude on behalf of Daniel Stephenson