test-completeness-guard
Skill1 starsChanged 58 days agoApache-2.0View on GitHub
Measure how many frozen public-surface names appear in a package's tests, and fail when that hit-rate is below an explicit floor. Use before claiming a package is "fully tested", when adding a sibling-package matrix census, or when a review asks whether exports have tests. Does not invent coverage floors.
In this repository39 other files it gives its agents.
- agent-core/AGENTS.mdAGENTS.md
- .agents/AGENTS.mdAGENTS.md
- AGENTS.mdAGENTS.md
- behavioral-regression/AGENTS.mdAGENTS.md
- claude-foundation/AGENTS.mdAGENTS.md
- config/AGENTS.mdAGENTS.md
- corpora/AGENTS.mdAGENTS.md
- demo/AGENTS.mdAGENTS.md
- docs/AGENTS.mdAGENTS.md
- examples/AGENTS.mdAGENTS.md
- experiments/AGENTS.mdAGENTS.md
- flow-corpus/AGENTS.mdAGENTS.md
- flow-protocol/AGENTS.mdAGENTS.md
- openspec/AGENTS.mdAGENTS.md
- scripts/AGENTS.mdAGENTS.md
- skills/AGENTS.mdAGENTS.md
- tests/AGENTS.mdAGENTS.md
- claude-foundation/CLAUDE.mdCLAUDE.md
- merge-gate-auditorSkill
- update-executive-reportSkill
- update-executive-reportSkill
- architecture-drift-guardSkill
- commonSkill
- corpus-guardianSkill
- dataset-lintSkill
- deploySkill
- e2e-matrix-sentinelSkill
- eval-corpus-forgeSkill
- hierarchical-recursive-brainstormSkill
- model-benchSkill
- openai-judgeSkill
- openspec-implementation-reviewSkill
- openspec-peer-reviewSkill
- openspec-quality-planSkill
- pre-pr-gateSkill
- project-setupSkill
- quality-gateSkill
- refactoring-decomposerSkill
- repo-invariant-reviewSkill
The file
Files
test-completeness-guard — public-surface test mention census
This skill answers a falsifiable question: of the names frozen in
public_surface_baseline.json (or backwards_compat_baseline.json), how many appear in
the test tree? It does not generate tests, does not invent a 95% product floor, and
does not write HUMAN_AUDIT. The 95% number in CI is this skill's own pytest-cov floor.
1. Preconditions
- A baseline JSON in the F-039 (or claude-foundation backwards-compat) shape.
- A directory of tests to scan.
- Python 3.10+, stdlib only.
2. Procedure
python skills/test-completeness-guard/scripts/check_completeness.py \
--baseline path/to/public_surface_baseline.json \
--tests path/to/tests \
--min-hit-rate 0 \
--format json \
--out report.json--min-hit-rate defaults to CompletenessConfig.min_hit_rate (0.0, report-only). Pass a
positive floor only when you mean it. Do not copy a 95% product claim from this skill's
CI coverage gate.
3. Output contract
- Exit 0 when hit-rate >= floor and the baseline was non-empty.
- Exit 1 when the floor is missed or the baseline exported nothing (vacuity refusal).
- Exit 2 on usage errors (missing files).
- JSON is sorted and path-stable (POSIX paths, no timestamps).
- stdout and
--outuse the same--format(text or json).
4. Validation gate
python scripts/validate_skill.py --skill . --tier structural,behavioralDoes it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

