genotoxic
What it does
This skill reviews the results of mutation testing, where small changes are made to code to check whether the tests catch them. It helps developers decide which surviving changes matter. It is for teams working on test quality.
When to use it
- βWhen mutation testing reports many surviving mutants and you need to decide which ones matter.
- βWhen you want to find where new unit tests would have the biggest effect.
- βWhen you want to find functions that would benefit from fuzz testing rather than more unit tests.
Skill link
https://github.com/trailofbits/skills/blob/main/plugins/trailmark/skills/genotoxic/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βMy mutation test left 40 survivors. Can you tell me which ones point to real gaps in my tests?β
5 new skills a week. 1 minute to read.
How it works
It runs mutation testing and a tool that removes test lines, then uses the code graph to sort the results into false alarms, missing tests, and fuzzing targets.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Genotoxic
Combines mutation testing and necessist (test statement removal) with code graph analysis to triage findings into actionable categories: false positives, missing unit tests, and fuzzing targets.
When to Use
- After mutation testing reveals survived mutants that need triage
- Identifying where unit tests would have the highest impact
- Finding functions that need fuzz harnesses instead of unit tests
- Prioritizing test improvements using data flow context
- Filtering out harmless mutants from actionable ones
- Finding unnecessary test statements that indicate weak assertions (necessist)
When NOT to Use
- Codebase has no existing test suite (write tests first)
- Pure documentation or configuration changes
- Single-file scripts with trivial logic
Prerequisites
- trailmark installed β if
uv run trailmarkfails, run:uv tool install trailmark
Python snippets: uv run --with trailmark python - (a tool env is not importable)
**DO NOT** fall back to "manual verification" or "manual analysis"
as a substitute for running trailmark. Install it first. If installation
fails, report the error instead of switching to manual analysis.
- A **mutation testing framework** for the target language β if the framework
command fails (not found, not installed), install it using the instructions
in [references/mutation-frameworks.md](references/mutation-frameworks.md).
**DO NOT** fall back to "manual mutation analysis" or skip mutation testing.
Install the framework first. If installation fails, report the error
instead of switching to manual mutation analysis.
- **necessist** (optional, recommended) β if the target language is
supported (Go, Rust, Solidity/Foundry, TypeScript/Hardhat,
TypeScript/Vitest, Rust/Anchor), install with `cargo install necessist`.
See [references/mutation-frameworks.md](references/mutation-frameworks.md)
for details.
- An existing test suite that passes
- **macOS environment**: Run `ulimit -n 1024` before any `mull-runner`
invocation. macOS Tahoe (26+) sets unlimited file descriptors by
default, which crashes Mull's subprocess spawning. See
[references/mutation-frameworks.md](references/mutation-frameworks.md)
for details.
---
## Rationalizations to Reject
| Rationalization | Why It's Wrong | Required Action |
|-----------------|----------------|-----------------|
| "All survived mutants need tests" | Many are harmless or equivalent | Triage before writing tests |
| "Mutation testing is too noisy" | Noise means you're not triaging | Use graph data to filter |
| "Unit tests cover everything" | Complex data flows need fuzzing | Check entrypoint reachability |
| "Dead code mutants don't matter" | Dead code should be removed | Flag for cleanup |
| "Low complexity = low risk" | Boundary bugs hide in simple code | Check mutant location |
| "Tool isn't installed, I'll do it manually" | Manual analysis misses what tooling catches | Install the tool first |
| "Necessist isn't mutation testing, skip it" | Necessist finds what mutation testing misses: weak tests | Run both when the language supports it |
---
## Quick Start
```bash
# 1. Build the code graph
uv run trailmark analyze --language auto --summary {targetDir}
# 2. Run mutation testing (language-dependent)
# Python:
uv run mutmut run --paths-to-mutate {targetDir}/src
uv run mutmut results
# 2b. Run necessist (if language supported)
necessist
# 3. Analyze results with this skill's workflow (Phase 3)
Workflow Overview
Phase 1: Graph Build β Parse codebase with trailmark
β
Phase 2: Mutation Run β Execute mutation testing framework
Phase 2b: Necessist Run β Remove test statements (optional, parallel)
β
Phase 3: Triage β Classify findings using graph data
β
Output: Categorized Report
βββ Corroborated (both tools flag same function β highest value)
βββ False Positives (harmless, skip)
βββ Missing Tests (write unit tests)
βββ Fuzzing Targets (set up fuzz harnesses)
Decision Tree
ββ Need to set up mutation testing for a language?
β ββ Read: references/mutation-frameworks.md
β
ββ Need to set up necessist or find weak test statements?
β ββ Read: references/mutation-frameworks.md (Necessist section)
β
ββ Need to understand the triage criteria in depth?
β ββ Read: references/triage-methodology.md
β
ββ Need to understand how graph data informs triage?
β ββ Read: references/grap
FAQ
Does it need an existing test suite?
Yes. The skill is meant for codebases that already have tests, and it advises writing tests first if there are none.
Which tools does it need?
It needs Trailmark and a mutation testing framework for your language. If the framework is missing, the skill guides you through installing it.
What is a surviving mutant?
It is a small change to the code that the tests did not catch, which can point to a gap in testing.
Details
Original description by the author
Graph-informed mutation testing triage. Parses codebases with Trailmark, runs mutation testing and necessist, then uses survived mutants, unnecessary test statements, and call graph data to identify false positives, missing test coverage, and fuzzing targets. Use when triaging survived mutants, analyzing mutation testing results, identifying test gaps, finding fuzzing targets from weak tests, running mutation frameworks (including circomvent and cairo-mutants), or using necessist.
repo: trailofbits/skills
Popularity
- GitHub stars
- 8.0k
- Ranking position
- #12728
- License
- CC-BY-SA-4.0
- Updated
- 11/2/2026
Comments
- β¦
More skills from this repository
audit-context-building
8.0kHelps your agent learn an unfamiliar codebase before a security review, mapping what each function assumes, guarantees and depends on.
algorand-vulnerability-scanner
8.0kHelps your agent scan Algorand smart contracts, written in TEAL or PyTeal, for 11 common security problems such as rekeying attacks and unchecked fees.
audit-prep-assistant
8.0kHelps your agent get a codebase ready for an outside security review, with static analysis, test coverage, dead-code cleanup and clear documentation.
cairo-vulnerability-scanner
8.0kHelps your agent scan Cairo smart contracts on StarkNet for 6 serious problems, including arithmetic overflow, risky cross-layer messages and signature replay.
Similar skills
test-driven-development
311kTeaches your agent to write a failing test first, watch it fail, then write the smallest code that passes, before building any feature or fix.
verification-before-completion
311kTeaches your agent to run real checks and read their output before claiming that a task, fix, or build is complete or passing.
migrate-to-shoehorn
310kReplaces risky type casts in your test files with the shoehorn library, so tests can use partial data and still pass type checks.