kmshihab7878/claude-code-setup/test-gap-analyzer
Claude Code and agent skill by kmshihab7878/claude-code-setup
- community
Checking that the SKILL.md file is still in the repository.
Automated test coverage gap detection and targeted test generation. Analyzes codebase for untested functions, uncovered branches, missing edge cases, and regression gaps. Produces prioritized test generation targets ranked by bug risk. Use when assessing test coverage, finding untested code, planning test sprints, or running the Quality department's UAOP self-improvement loop.
Install
npx vskill@latest install kmshihab7878/claude-code-setup/test-gap-analyzerSKILL.md
Test Gap Analyzer — Quality Intelligence Engine
Automated coverage gap detection that feeds the Quality department's UAOP loop. Find what's untested, rank by risk, generate tests for the highest-risk gaps first. This is UAOP Stage 1 (Intelligence) + Stage 5 (Self-Improvement) for Quality.
When to use
- Before a release — "are we covered?"
- After adding new features — "what's untested?"
- After a production bug — "why didn't our tests catch this?"
- Sprint planning — "what should we test next?"
- Monthly quality review — "where are we improving, where are we regressing?"
When NOT to use
- Writing individual tests (use
test-driven-development) - Debugging a specific failure (use
debug) - Reviewing test methodology (use
testing-methodology)
Pipeline
Step 1: Coverage Scan
Run coverage tools and collect raw data:
Extract:
- Line coverage % — per module, per file
- Branch coverage % — conditional paths not exercised
- Uncovered functions — public functions with zero test coverage
- Uncovered files — entire files with no tests
Step 2: Risk-Rank Gaps
Not all gaps are equal. Rank by bug risk:
Step 3: Classify Gap Types
| Gap Type | Description | Priority | Test Type Needed | |
|---|---|---|---|---|
| Critical path uncovered | Auth, payments, data mutation with 0% coverage | P0 | Unit + integration | |
| High-change no-test | Files changed >5x in 90 days with <50% coverage | P0 | Regression tests | |
| Branch gaps | Conditional paths (error handling, edge cases) never exercised | P1 | Edge case + property-based | |
| API contract gaps | Endpoints without request/response validation tests | P1 | Contract tests | |
| E2E flow gaps | Critical user journeys without end-to-end tests | P1 | E2E (Playwright) | |
| Integration gaps | DB/Redis/external API interactions untested with real deps | P2 | Integration tests | |
| Regression gaps | Production bugs that had no test (and still don't) | P0 | Regression tests | |
| Flaky tests | Tests that pass/fail non-deterministically | P1 | Fix or quarantine |
Step 4: Produce Gap Report
Step 5: Generate Test Targets
For each P0 gap, produce a test specification:
Step 6: Self-Improvement Loop (UAOP Stage 5)
After tests are written and run:
Cadence
Tools Used
| Tool | Purpose | |
|---|---|---|
| pytest --cov | Python line + branch coverage | |
| vitest --coverage | Frontend coverage | |
| playwright | E2E test execution | |
| github MCP | PR coverage diffs, change frequency | |
| code-review-graph MCP | Blast radius analysis for risk ranking | |
| sequential MCP | Multi-step gap analysis reasoning |
Agents
| Agent | Role | |
|---|---|---|
| quality-engineer (L2) | Owns the gap analysis, sets priorities | |
| tester (L6) | Writes tests targeting identified gaps | |
| test-results-analyzer (L6) | Analyzes results, identifies flaky tests | |
| code-reviewer (L6) | Reviews test quality before merge | |
| debugger (L6) | Investigates why gaps exist (missing test or untestable code?) |
UAOP Integration
Quality KPIs (Self-Improvement Metrics)
| Metric | Target | Alert | |
|---|---|---|---|
| Line coverage | >80% | Drops below 75% | |
| Branch coverage | >70% | Drops below 65% | |
| Bug escape rate | <5% | Rises above 10% | |
| Flaky test count | 0 | Any new flaky test | |
| Regression debt | 0 | Any prod bug without regression test | |
| Time to first test (new code) | Same PR | Tests in separate PR |
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/test-gap-analyzer/SKILL.md
Popularity
- Repository stars
- 6
- Repository forks
- 1
- 7-day trend score
- 10
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/kmshihab7878/claude-code-setup/test-gap-analyzer)