with one click
coverage-improvement
// Guide systematic coverage improvement using vitest-agent MCP tools. Use when improving code coverage, targeting uncovered lines, or working toward coverage targets.
// Guide systematic coverage improvement using vitest-agent MCP tools. Use when improving code coverage, targeting uncovered lines, or working toward coverage targets.
[HINT] Download the complete skill directory including SKILL.md and all related files
| name | coverage-improvement |
| description | Guide systematic coverage improvement using vitest-agent MCP tools. Use when improving code coverage, targeting uncovered lines, or working toward coverage targets. |
Systematic approach to identifying and covering untested code using MCP tools.
Use test_coverage to see project-wide coverage gaps:
For a specific file, use file_coverage({ filePath: "src/foo.ts" })
to get per-metric values and uncovered line ranges.
Use test_for_file({ filePath: "src/foo.ts" }) to find which test
files already cover the source file. Then use
test_get({ fullName: "Suite > test name" }) to understand
individual test scope and history.
Focus on the uncovered lines from step 1:
run_tests({ files: ["path/to/test.ts"] })file_coverage to check the file's updated coveragetest_coverage to verify project-wide improvementtest_trends to confirm coverage direction is improvingFocus on files with the largest coverage gaps first. Files near the threshold ("at-risk" files) are the highest priority since a small regression could push them below the threshold.
Use note_create to document: