coverage — Claude Code skill: what it does, how to install
This skill maps tested and untested parts of an application. Use it when you need a clear list of missing tests before planning the next checks.
/plugin marketplace add alirezarezvani/claude-skills
/plugin install pw@claude-code-skillsWhat coverage does
coverage first maps the application surface: routes and pages, interactive components, API endpoints, and user flows. It uses the Explore subagent for that pass. Then it scans *.spec.ts and *.spec.js files, checking page.goto() calls, locator usage, and mocked or exercised API endpoints.
The result includes a coverage matrix, an estimated coverage percentage, and a prioritized list of gaps. Each gap can include a suggested test count, a template from templates/, and an effort label such as quick, medium, or complex. With the user's approval, the skill can call /pw:generate for selected gaps.
Install it when you need a project-wide test gap review. The analysis is more useful when the project already contains *.spec.ts or *.spec.js tests.
What it helps with
- find pages with no tests
- map API endpoints to existing checks
- spot untested user flows
- rank coverage gaps by priority
- draft a plan for missing tests
Example prompts for the agent
- Analyze the test coverage and show what is not tested.
- Find coverage gaps across routes, components, and APIs.
- Create a test plan for the highest-priority gaps.
How to install coverage
1Plugin marketplace
/plugin marketplace add alirezarezvani/claude-skills/plugin install pw@claude-code-skillsThis installs the whole pw plugin with all its skills
2Skills CLI (Vercel)
npx skills add alirezarezvani/claude-skills --skill coverage -a claude-code3Manually: put the files in place
~/.claude/skills/coverage/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/coverage/
Manually: put the files in place
.agents/skills/coverage/SKILL.mdFor all projects use ~/.agents/skills/
Manually: put the files in place
.cursor/skills/coverage/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install alirezarezvani/claude-skills coverage2Manually: put the files in place
.github/skills/coverage/SKILL.mdPlatform CLI
gemini skills install https://github.com/alirezarezvani/claude-skills --path engineering-team/playwright-pro/skills/coverageManually: put the files in place
.devin/skills/coverage/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set349
The whole set →Similar
Questions about coverage
How do I install coverage in Claude Code?
Run npx skills add alirezarezvani/claude-skills --skill coverage -a claude-code.
What does coverage do?
The skill compares the application's testable surface with existing tests and builds a coverage matrix. It also ranks gaps and suggests a test plan.
Which files does coverage analyze?
It scans *.spec.ts and *.spec.js files, then looks for routes, components, API endpoints, and user flows in the project.
Source text
SKILL.md · MIT
--- name: "coverage" description: >- Analyze test coverage gaps. Use when user says "test coverage", "what's not tested", "coverage gaps", "missing tests", "coverage report", or "what needs testing". --- # Analyze Test Coverage Gaps Map all testable surfaces in the application and identify what's tested vs. what's missing. ## Steps ### 1. Map Application Surface Use the `Explore` subagent to catalog: **Routes/Pages:** - Scan route definitions (Next.js `app/`, React Router config, Vue Router, etc.) - List all user-facing pages with their paths **Components:** - Identify interactive components (forms, modals, dropdowns, tables) - Note components with complex state logic **API Endpoints:** - Scan API route files or backend controllers - List all endpoints with their methods **User Flows:** - Identify critical paths: auth, checkout, onboarding, core features - Map multi-step workflows ### 2. Map Existing Tests Scan all `*.spec.ts` / `*.spec.js` files: - Extract which pages/routes are covered (by `page.goto()` calls) - Extract which components are tested (by locator usage) - Extract which API endpoints are mocked or hit - Count tests per area ### 3. Generate Coverage Matrix ``` ## Coverage Matrix | Area | Route | Tests | Status | |---|---|---|---| | Auth | /login | 5 | ✅ Covered | | Auth | /register | 0 | ❌ Missing | | Auth | /forgot-password | 0 | ❌ Missing | | Dashboard | /dashboard | 3 | ⚠️ Partial (no error states) | | Settings | /settings | 0 | ❌ Missing | | Checkout | /checkout | 8 | ✅ Covered | ``` ### 4. Prioritize Gaps Rank uncovered areas by business impact: 1. **Critical** — auth, payment, core features → test first 2. **High** — user-facing CRUD, search, navigation 3. **Medium** — settings, preferences, edge cases 4. **Low** — static pages, about, terms ### 5. Suggest Test Plan For each gap, recommend: - Number of tests needed - Which template from `templates/` to use - Estimated effort (quick/medium/complex) ``` ## Recommended Test Plan ### Priority 1: Critical 1. /register (4 tests) — use auth/registration template — quick 2. /forgot-password (3 tests) — use auth/password-reset template — quick ### Priority 2: High 3. /settings (4 tests) — use settings/ templates — medium 4. Dashboard error states (2 tests) — use dashboard/data-loading template — quick ``` ### 6. Auto-Generate (Optional) Ask user: "Generate tests for the top N gaps? [Yes/No/Pick specific]" If yes, invoke `/pw:generate` for each gap with the recommended template. ## Output - Coverage matrix (table format) - Coverage percentage estimate - Prioritized gap list with effort estimates - Option to auto-generate missing tests
© Alireza Rezvani · MIT · alirezarezvani/claude-skills