{"id":"c539c373-e483-43a8-a00c-258e6718b9c2","shortId":"uFhpYa","kind":"skill","title":"coverage","tagline":"Check test coverage for unstaged changes. Use when user asks to \"check coverage\", \"/coverage\", or wants to see which unstaged changes lack test coverage. Don't use for projects without lcov coverage output, running the full test suite without coverage, or checking coverage of alr","description":"# Coverage Check\n\n## Context\n\nRun in parallel:\n- `git diff --name-only` - get unstaged files\n- `git diff -U0 --no-color` - get changed line numbers\n\n## Commands\n\nSequential:\n1. `npm run test:ci` - vitest with coverage\n2. `npm run coverage:report` - generate lcov/text reports\n\n## Workflow\n\n1. Get unstaged files and line ranges (parallel):\n   - `git diff --name-only`\n   - `git diff -U0 --no-color`\n2. Run coverage:\n   - `npm run test:ci`\n   - `npm run coverage:report`\n3. Save diff to a temp file, then run:\n   ```bash\n   git diff -U0 --no-color > /tmp/changes.diff\n   python3 scripts/parse-lcov.py --lcov coverage/lcov.info --diff /tmp/changes.diff\n   ```\n4. Report uncovered lines from stdout: `file.ts:42`\n5. Summary from stderr: X/Y changed lines covered\n\n## LCOV Format\n\nParse `coverage/lcov.info`:\n```\nSF:src/utils/helper.ts\nDA:10,1    # line 10, covered (hit 1 time)\nDA:11,0    # line 11, NOT covered\nDA:12,5    # line 12, covered (hit 5 times)\nend_of_record\n```\n\nKey fields:\n- `SF:` -- source file path\n- `DA:line,hits` -- `0` = uncovered, `>0` = covered\n- `end_of_record` -- end of file section\n\nMatch `SF:` paths to `git diff` files. For each changed line, check `DA:` entry. If `hits` is `0`, report as uncovered.\n\n## Anti-Rationalization\n\n| Excuse | Rebuttal |\n|---|---|\n| \"Coverage doesn't guarantee quality\" | True, but uncovered code guarantees zero automated verification. |\n| \"It's just a config change\" | Config changes break production too. If there's logic, check coverage. |\n| \"100% is overkill\" | Nobody asked for 100%. Check that *changed* lines are covered. |\n| \"The test suite is already green\" | Green suite with uncovered changes = false confidence. |\n\n## Rules\n\n- Only analyze unstaged changes (`git diff`)\n- Use sequential commands: `test:ci` then `coverage:report`\n- Use `scripts/parse-lcov.py` to parse lcov data and map to changed lines\n- Report uncovered lines: `file.ts:42`\n- Ignore files without coverage data (non-code files)\n\n## Error Handling\n\n- `npm run test:ci` fails -- report test failures and stop\n- `coverage/lcov.info` not found -- verify `coverage.reporter` includes `lcov` in test runner config\n- `git diff` returns no changes -- report no unstaged changes to check","tags":["coverage","agent","skills","helderberto","agent-skills","ai-tools","antigravity","claude-code","cursor","developer-tools","gemini-cli","markdown"],"capabilities":["skill","source-helderberto","skill-coverage","topic-agent-skills","topic-ai-tools","topic-antigravity","topic-claude-code","topic-cursor","topic-developer-tools","topic-gemini-cli","topic-markdown","topic-plugin","topic-sdlc","topic-skills","topic-tracer-bullet"],"categories":["agent-skills"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/helderberto/agent-skills/coverage","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add helderberto/agent-skills","source_repo":"https://github.com/helderberto/agent-skills","install_from":"skills.sh"}},"qualityScore":"0.454","qualityRationale":"deterministic score 0.45 from registry signals: · indexed on github topic:agent-skills · 8 github stars · SKILL.md body (2,213 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-05-18T19:09:12.568Z","embedding":null,"createdAt":"2026-05-18T13:14:52.538Z","updatedAt":"2026-05-18T19:09:12.568Z","lastSeenAt":"2026-05-18T19:09:12.568Z","tsv":"'/coverage':15 '/tmp/changes.diff':136,142 '0':175,201,203,229 '1':73,90,166,171 '10':165,168 '100':268,274 '11':174,177 '12':181,184 '2':81,109 '3':120 '4':143 '5':150,182,187 'alr':46 'alreadi':285 'analyz':296 'anti':234 'anti-ration':233 'ask':11,272 'autom':249 'bash':129 'break':259 'chang':7,22,68,155,221,256,258,277,291,298,318,360,364 'check':2,13,43,48,223,266,275,366 'ci':77,115,305,338 'code':246,331 'color':66,108,135 'command':71,303 'confid':293 'config':255,257,355 'context':49 'cover':157,169,179,185,204,280 'coverag':1,4,14,25,33,41,44,47,80,84,111,118,238,267,307,327 'coverage.reporter':349 'coverage/lcov.info':140,161,345 'da':164,173,180,198,224 'data':314,328 'diff':54,62,99,104,122,131,141,217,300,357 'doesn':239 'end':189,205,208 'entri':225 'error':333 'excus':236 'fail':339 'failur':342 'fals':292 'field':193 'file':60,93,126,196,210,218,325,332 'file.ts:42':149,323 'format':159 'found':347 'full':37 'generat':86 'get':58,67,91 'git':53,61,98,103,130,216,299,356 'green':286,287 'guarante':241,247 'handl':334 'hit':170,186,200,227 'ignor':324 'includ':350 'key':192 'lack':23 'lcov':32,139,158,313,351 'lcov/text':87 'line':69,95,146,156,167,176,183,199,222,278,319,322 'logic':265 'map':316 'match':212 'name':56,101 'name-on':55,100 'no-color':64,106,133 'nobodi':271 'non':330 'non-cod':329 'npm':74,82,112,116,335 'number':70 'output':34 'overkil':270 'parallel':52,97 'pars':160,312 'path':197,214 'product':260 'project':30 'python3':137 'qualiti':242 'rang':96 'ration':235 'rebutt':237 'record':191,207 'report':85,88,119,144,230,308,320,340,361 'return':358 'rule':294 'run':35,50,75,83,110,113,117,128,336 'runner':354 'save':121 'scripts/parse-lcov.py':138,310 'section':211 'see':19 'sequenti':72,302 'sf':162,194,213 'skill' 'skill-coverage' 'sourc':195 'source-helderberto' 'src/utils/helper.ts':163 'stderr':153 'stdout':148 'stop':344 'suit':39,283,288 'summari':151 'temp':125 'test':3,24,38,76,114,282,304,337,341,353 'time':172,188 'topic-agent-skills' 'topic-ai-tools' 'topic-antigravity' 'topic-claude-code' 'topic-cursor' 'topic-developer-tools' 'topic-gemini-cli' 'topic-markdown' 'topic-plugin' 'topic-sdlc' 'topic-skills' 'topic-tracer-bullet' 'true':243 'u0':63,105,132 'uncov':145,202,232,245,290,321 'unstag':6,21,59,92,297,363 'use':8,28,301,309 'user':10 'verif':250 'verifi':348 'vitest':78 'want':17 'without':31,40,326 'workflow':89 'x/y':154 'zero':248","prices":[{"id":"27bcda46-5a1a-41b6-98d3-dc1b3ef17fe5","listingId":"c539c373-e483-43a8-a00c-258e6718b9c2","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"helderberto","category":"agent-skills","install_from":"skills.sh"},"createdAt":"2026-05-18T13:14:52.538Z"}],"sources":[{"listingId":"c539c373-e483-43a8-a00c-258e6718b9c2","source":"github","sourceId":"helderberto/agent-skills/coverage","sourceUrl":"https://github.com/helderberto/agent-skills/tree/main/skills/coverage","isPrimary":false,"firstSeenAt":"2026-05-18T13:14:52.538Z","lastSeenAt":"2026-05-18T19:09:12.568Z"}],"details":{"listingId":"c539c373-e483-43a8-a00c-258e6718b9c2","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"helderberto","slug":"coverage","github":{"repo":"helderberto/agent-skills","stars":8,"topics":["agent-skills","ai","ai-tools","antigravity","claude-code","cursor","developer-tools","gemini-cli","markdown","plugin","sdlc","skills","tracer-bullet"],"license":"mit","html_url":"https://github.com/helderberto/agent-skills","pushed_at":"2026-05-14T11:37:47Z","description":"My personal SDLC toolbelt for AI coding agents — PRD to ship.","skill_md_sha":"b642e6d523c01c25b2aa11fc311ef291841663b1","skill_md_path":"skills/coverage/SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/helderberto/agent-skills/tree/main/skills/coverage"},"layout":"multi","source":"github","category":"agent-skills","frontmatter":{"name":"coverage","description":"Check test coverage for unstaged changes. Use when user asks to \"check coverage\", \"/coverage\", or wants to see which unstaged changes lack test coverage. Don't use for projects without lcov coverage output, running the full test suite without coverage, or checking coverage of already-committed changes."},"skills_sh_url":"https://skills.sh/helderberto/agent-skills/coverage"},"updatedAt":"2026-05-18T19:09:12.568Z"}}