Agent skill
Test Coverage Analysis
Measure and improve test coverage by identifying untested code paths and prioritizing high-risk areas for testing
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/testing/test-coverage-analysis-dasien-remotecredentialrequ
SKILL.md
Test Coverage Analysis
Purpose
Measure and improve test coverage to ensure code is adequately tested and identify untested areas that may contain bugs.
When to Use
- Evaluating test suite quality
- Identifying untested code paths
- Setting testing goals
- Validating test completeness
Key Capabilities
- Coverage Measurement - Run coverage tools and interpret results
- Gap Analysis - Identify critical untested code
- Prioritization - Focus on high-risk areas first
Approach
- Run coverage tool on test suite
- Review coverage report (line, branch, function coverage)
- Identify uncovered critical paths
- Prioritize based on risk and complexity
- Write tests for important gaps
- Re-run coverage to validate improvement
Example
Context: Coverage report shows 75% line coverage
Analysis:
- Core business logic: 95% covered ✓
- Error handling: 45% covered ⚠️
- Edge cases: 30% covered ⚠️
- UI code: 60% covered
Priority:
1. Add tests for error handling (high risk)
2. Cover common edge cases
3. UI testing (lower priority)
Best Practices
- ✅ Aim for 80%+ coverage on critical code
- ✅ Focus on meaningful tests, not just coverage numbers
- ✅ Test edge cases and error paths
- ❌ Avoid: Chasing 100% coverage on trivial code
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?