coverage
Skill400 starsChanged 33 days agoMITView on GitHub
How to approach code coverage in this project. Use when coverage CI fails, when writing tests for new code, when deciding whether to add // nocov, or when you need to make untestable code testable. Also use proactively when writing new code to ensure it will be coverable.
28 other projects use a version of this.
Adopted by
Most recently taken up by
- wboayue/rust-ibapitheir own version, first seen Nov 9, 2026
- KadirHarmanc/nazar-skilltheir own version, first seen Nov 8, 2026
- LeanMeanCleanApps/CleanModelContextProtocoltheir own version, first seen Nov 8, 2026
- AsiaOstrich/EngramGraphtheir own version, first seen Nov 8, 2026
- grodowski/undercover-claudetheir own version, first seen Nov 7, 2026
- AsiaOstrich/universal-dev-standardstheir own version, first seen Nov 1, 2026
Used with
Projects with it also use scan, lint and 9 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
rajnavakotiSkillscan
Run the AI dashboard scanner and generate the HTML report.
Also in 4 projects that use this
Microsoft AzureSkilllint
Run all linting and spell checking for TypeScript and Rust code. Run this before committing to catch style issues, clippy warnings, and misspellings.
Also in 4 projects that use this
julienamorganSkillprofile
Researches the user's market, competitors, and competitive positioning to build a complete ICP profile. Shows findings for user approval before proceeding. Triggers: /profile, "research my market", "who are my competitors". Reads: ./gtm/company.md, ./gtm/icp.md. Writes: updates ./gtm/icp.md with competitive positioning. Standalone: yes (asks for domain if company.md missing).
Also in 3 projects that use this
asterkinSkilladr
Create Architecture Decision Records (ADRs) following project standards. Guides template usage, process, and best practices for documenting architecturally significant decisions.
Also in 4 projects that use this
anombyte93Skilldiscover
Phase 1 of the prd-taskmaster pipeline: brainstorm-driven discovery. Delegates to superpowers:brainstorming in Interactive Mode (one adaptive question at a time), or self-brainstorms in Autonomous Mode when no user is present. Intercepts before the brainstorming chain hands off to writing-plans — this skill owns the exit. Extracts constraints, calibrates scale (Solo / Team / Enterprise), and advances the pipeline to GENERATE.
Also in 3 projects that use this
MicrosoftSkillworktree
Create, reuse or clean up a dedicated git worktree for working on a pull request or a private branch. Use from any PR-scoped workflow that needs an isolated checkout to keep current code and build output untouched.
Also in 3 projects that use this
Other versions28 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 28
- FalkorDB/FalkorDB★ 10ksame name
- pydantic/monty★ 8.9ksame name
- LiberatedPixelCup/Universal-LPC-Spritesheet-Character-Generator★ 1.9ksame name
- firedancer-io/firedancer★ 1.6ksame name
- wboayue/rust-ibapi★ 400same name
- nockawa/Typhon★ 253same name
- Amplicode/spring-skills★ 126same name
- AsiaOstrich/universal-dev-standards★ 84same name
- hass-energy/haeo★ 77same name
- drafthq/draft★ 40same name
18 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository8 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .claude/CLAUDE.mdCLAUDE.md
- add-library-supportSkill
- changelogSkill
- new-default-generatorSkill
- new-generatorSkill
- new-settingSkill
- self-reviewSkill
The file
We split this skill into the rules it gives an agent
5 rules. 0 are common, 3 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 25 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 22
Validate against independent sources: if you can obtain the correct answer some other way - e.g.
- Distinctive: line 27
When CI coverage fails:
- Distinctive: line 29
Read the failure output — it lists each uncovered file:line and content.
- Very specific: line 33
Dead code: if it's truly unreachable, delete it, or replace it with an unreachable!
- Very specific: line 34
Run just check-coverage locally if cargo-llvm-cov is available to iterate faster than CI.
“Common” is measured: kept by at least 6 in 10 of the 25 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Code Coverage
This project requires 100% line coverage for new code, with explicit nocov annotations only allowed under rare circumstances and with human permission.
This is implemented as a ratchet which counts the number of lines annotated as not requiring coverage. If the number of excluded lines exceeds the ratchet value, or if there are any uncovered lines without a // nocov annotation, the coverage check fails.
The ratchet is not a budget
The nocov count in .github/coverage-ratchet.json tracks excluded lines and can only decrease. Just because previous work reduced the count does not mean you have implicit permission to add new uncovered lines. Think of the ratchet as immediately ratcheting down after any reduction — the slack is gone.
You may not add // nocov annotations without explicit human permission. If you think code is genuinely untestable, your first move should be to refactor it for testability, not to annotate it. See references/patterns.md for testability refactoring examples.
Writing good tests
Tests should catch real bugs, not mirror the implementation.
- Validate against independent sources: if you can obtain the correct answer some other way - e.g. checking it against an externally defined source, or calculating it through some simpler more expensive method - then you should validate against that in the test.
- Think in terms of what could go wrong: a test that would still pass after introducing a bug is not testing anything. Figure out ways in which the code could genuinely be wrong and write tests that would catch that if it were.
Diagnosing coverage failures
When CI coverage fails:
- Read the failure output — it lists each uncovered file:line and content.
- Categorize each uncovered line:
- Just needs testing: most code that has not been covered just needs a test written for it. Your default assumption should be that it is straightforwardly testable and you just need to write a normal test.
- Needs refactoring: some code cannot easily be tested in its current form and needs refactoring to make it testable. See
references/patterns.mdfor information on how to do that. - Dead code: if it's truly unreachable, delete it, or replace it with an
unreachable!annotation.
- Run
just check-coveragelocally ifcargo-llvm-covis available to iterate faster than CI.
For details on how the coverage script works and what it auto-excludes, see references/internals.md.
Does 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.

