Supercov
Measure test coverage and mutation testing to find untested code and generate focused tests.
Installation
- Make sure Claude is on your device and in your terminal.
Skills load from
~/.claude/skills/when Claude Code starts up — so you need it on your machine first. If you don't have it yet, install it once with the command below, then runclaudein any terminal to verify.One-time setupnpm i -g @anthropic-ai/claude-codeAlready have it? Skip ahead.
- Paste into Claude Code or into your terminal.
This copies the whole skill folder into
~/.claude/skills/supercov-supercorp-ai/— the SKILL.md plus any scripts, reference docs, or templates the skill ships with. Works for every skill.What this command does
- Makes a new, empty temporary folder.
- Downloads the skill's folder,
plugins/supercov/skills/supercov, fromgithub.com/supercorp-ai/supercov(branchmain), the GitHub repository it's listed from. You get the version that is there now, not a copy we keep. - Copies that folder to
~/.claude/skills/supercov-supercorp-ai/. - Deletes the temporary folder.
Installing runs none of the skill's files; it only downloads and copies them. When you later use the skill, Claude follows its SKILL.md and may run scripts that come with it. Read them first.
Faster alternative (instruction-only skills)
Skips the clone and grabs only the SKILL.md file. Don't use this if the skill ships Python scripts, reference markdowns, or asset templates — they won't be downloaded and the skill will fail when it tries to load them.
Quick install (SKILL.md only)Sign up to copy - Restart Claude Code.
Quit and reopen Claude Code (or any other agent that loads from
~/.claude/skills/). New skills are picked up on startup. - Just ask Claude.
Skills auto-activate when your request matches the skill's description — no slash command needed. Trigger phrases live in the skill's own frontmatter; you can read them in the “What this skill does” section above.
Prefer to read the source first? Open on GitHub.
When Claude uses it
Measures test coverage, mutation testing and code quality in a repository with the supercov CLI, and turns what it finds into small, focused tests or fixes. Use when the user asks to add or improve tests, find untested code or raise coverage, check whether tests would catch bugs (mutation testing, surviving mutants), or find what to refactor. Works with JavaScript, TypeScript, Python, Ruby, Rust, Go, Java and Kotlin projects.
What this skill does
Supercov
Supercov runs the project's own test command and changes no source, tests or configuration. npx supercov docs <topic> prints the guide for the installed version; read it for anything not shown here. Topics: agent-loop, mutation, quality, supported-suites, troubleshooting.
Add a test
- Measure the full suite:
npx supercov -- <test command>, for examplenpx supercov -- npm test. - List targets with
npx supercov runs latest gaps --limit 5, pick one, and inspect it withnpx supercov runs latest file <path>. - Write one focused test. Change only tests unless the user asks otherwise.
- Rerun the same command and report the test and the coverage before and after.
Check that the tests catch bugs
Coverage says code ran, not that a test would fail if it were wrong. Mutation testing changes the code one small edit at a time (a mutant) and checks that a test fails. Use it after writing tests, to check that they assert something, when the user asks whether the tests are good enough, and on a pull request or branch.
- Run
npx supercov mutants -- <test command>. It measures the suite, lists the mutants and runs each against the tests that reach it. On a branch or pull request, add--diff <base>(for example--diff origin/main) to keep only the mutants on changed lines. - Read the survivors. The pass's summary ends with them;
npx supercov runs latest mutants --status survivedlists them all, andnpx supercov runs latest mutants <path>lists a file's mutants by line, each with what it changes, its verdict and why. A weak status ofnot-infectedmeans a test ran the code but never gave it an input where the change matters (for<to<=, operands that are equal);not-reachedthat no test ran it. - Write a test that fails on one surviving mutant, with an assertion on the value it changes. Change only tests.
- Run
npx supercov mutantsagain and report which mutants are now killed and which still survive.
Mutation testing is fully supported for JavaScript and TypeScript, and in preview for Python, Rust, Go and Ruby; Java and Kotlin have no mutants yet. Mutants under a runner Supercov has no strong driver for are error, never survivors.
Some mutants no test can tell apart from the original. Do not weaken code to kill them: say why, and the user can list them in supercov.accepted.json. Mutation testing reruns the tests, so prefer --diff on a large project.
Quality
npx supercov qualityranks files by code smells, andnpx supercov quality patchreports what a change introduced.- It sends source files to TypeSafe using the
TYPESAFE_API_KEYenvironment variable. A user who set the key has opted in, so run it without asking again. If the key is missing the command says so: tell the user how to set it, then answer from reading the code and say Supercov did not check it.
Without Node.js 22 or newer, install Supercov as the language guide at https://supercov.com/docs says, and run supercov instead of npx supercov.
Related skills
Documentation Co-Authoring
anthropics
Guide structured workflows for writing docs, proposals, and technical specs collaboratively.
MCP Server Builder
anthropics
Build protocol servers that connect language models to external APIs and services.
Skill Builder & Optimizer
anthropics
Create, edit, and optimize Claude skills with performance testing and benchmarking.
Multi-Component Web Artifacts
anthropics
Build complex React artifacts with Tailwind CSS and shadcn/ui components.