mutation-testing

Evaluates test suite quality by injecting code mutants and analyzing surviving mutations.

Updated Dec 29, 2025
One-click install
npx skills add https://github.com/snoodleboot-io/discrecontinual_equations --skill mutation-testing-snoodleboot-io
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: mutation-testing
Source: https://github.com/snoodleboot-io/discrecontinual_equations/tree/main/.claude/skills/mutation-testing
Command: npx skills add https://github.com/snoodleboot-io/discrecontinual_equations --skill mutation-testing-snoodleboot-io

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Line and branch coverage only prove code executed during tests, not that tests would catch real bugs. This Skill applies mutation testing to reveal which behaviors are genuinely verified by introducing small code changes and checking whether tests fail. ## Core Features & Use Cases - Mutant Analysis: Explains the standard mutation operators (boundary, negation, arithmetic, constant, return value, statement removal) and what each surviving mutant proves about test gaps. - Score Interpretation: Guides reading mutation scores, handling equivalent mutants, and setting CI break thresholds that ratchet upward instead of chasing 100%. - Cost-Scoped Execution: Provides strategies for diff-scoped incremental runs in PRs and nightly full sweeps, since mutation testing cost scales with mutants times covering tests. - Use Case: A pricing function shows 100% coverage but mutants survive on the discount boundary and membership check; the Skill walks through triaging each survivor into missing assertion, missing input, equivalent, or dead code and writing the parametrized tests that kill them. ## Quick Start Ask the assistant to apply mutation testing to a specific module and triage the surviving mutants into actionable test improvements.

Frequently Asked Questions about mutation-testing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I start mutation testing on my codebase?▼

Install a mutation tool for your language such as mutmut for Python, Stryker for JavaScript, or PIT for Java, then scope it to high-consequence domain logic. Run it, review the survivor list, and triage each survivor into missing assertion, missing input, equivalent, or dead code.

What is a good mutation testing score?▼

A score of 80% or higher on core domain logic is strong, and 60% suite-wide is respectable. Chasing 100% is counterproductive because equivalent mutants cannot be killed by any test, so treat the score as a trend line and the survivor list as the real deliverable.

Why is mutation testing so slow in CI?▼

Runtime scales with the number of mutants multiplied by the tests covering each mutated line, so a single module can take 30 to 60 minutes. Use diff-scoped incremental runs for pull requests and schedule full sweeps nightly rather than in the merge gate.

What is an equivalent mutant in mutation testing?▼

An equivalent mutant is a syntactic change with no semantic effect, so no test can ever kill it, such as changing a loop condition when the counter increments by exactly one. Mark confirmed equivalents with a reason so they stop reappearing in every run.

Does 100% line coverage mean my tests are good?▼

No, line coverage only proves code executed during the test run, not that a wrong implementation would fail. Mutation testing exposes this gap by showing mutants that survive despite full coverage, revealing untested boundaries, branches, and side effects.