Test coverage

From berkcangumusisik/claude-code-practices · View interactive version

Test coverage is an AI agent skill from the GitHub repository berkcangumusisik/claude-code-practices. Runs coverage report, identifies untested code, and generates missing tests

How to use this skill

Skill file

Test Coverage Analysis

  1. Run coverage:
# Detect test runner from package.json
cat package.json | grep -E '"test"|"coverage"'

Then run the appropriate coverage command (e.g., bun test --coverage, npx jest --coverage, go test ./... -cover).

  1. Parse results and find:
  1. For the 3 most under-tested files:
  1. Report:
Coverage: X% (was Y% if previous data available)

Files needing attention:
  src/auth/token.ts       42% → generated 8 tests
  src/utils/format.ts     61% → generated 4 tests
  src/api/handler.ts      70% → generated 3 tests
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.