Test Coverage Management
Track and expand test coverage systematically.
Usage
- •
/testing:test-coverage status- Current coverage metrics - •
/testing:test-coverage opportunities- Find high-impact files - •
/testing:test-coverage expand [area]- Expand specific area
Priority Matrix
High Priority (Zero Coverage)
- •Core business logic files
- •Utility functions
- •Data stores
Medium Priority (Partial Coverage)
- •Modules with < 50% coverage
Lower Priority
- •Well-covered files needing edge cases
Workflow
- •Run coverage report to identify targets
- •Pick 2-3 high-priority files
- •Create tests using appropriate patterns (see
testing:unit-testsskill) - •Verify coverage improvement
- •Repeat
Reports
bash
# HTML report <test-coverage-command> --reporter=html # JSON data <test-coverage-command> --reporter=json # Summary only <test-coverage-command> --reporter=text-summary
Expansion Process
- •Identify files with zero or low coverage
- •Prioritize by: business impact, change frequency, complexity
- •Create tests covering: happy path, edge cases, error conditions
- •Verify improvement
- •Track progress over time