cargo-mutants
cargo-mutants is a free, open-source tool for mutation testing Rust projects.
What cargo-mutants is
cargo-mutants is a free, open-source tool for mutation testing Rust projects. It introduces potential code changes and checks whether the test suite catches them; surviving mutants can point to functions that may need better tests. Run `cargo mutants` from a Rust source directory. The tool needs no source-tree changes or extra setup before installation and use, and can be installed with Cargo, cargo-binstall, or binaries from GitHub releases. It supports incremental analysis, parallel execution, surviving-mutant reports, and mutation quality gates. Useful results depend on reliable, non-flaky tests that run with `cargo test` or `cargo nextest`. Options can be stored in `.cargo/mutants.toml`, and individual items or mutation patterns can be excluded. The project documents CI workflows, including GitHub Actions examples. Runs can take longer as the number of viable mutations and test-suite runtime increase. It requires a reasonably recent stable, nightly, or beta Rust toolchain; the source tree must build for the host platform, and build systems other than Cargo are not supported. The project is MIT licensed and supplied without warranty.
Good
- Free and open source under the MIT license
- Supports incremental analysis and parallel execution
- Reports surviving mutants and mutation quality gates
- Provides documented CI workflow examples
Watch out
- Cross-compilation is not supported
- Build systems other than Cargo are unsupported
- Useful results require reliable, non-flaky tests
- Runs can take longer with more mutants or slower tests
Who it suits
It suits Rust developers who want to find gaps in test coverage and can run reliable tests with Cargo or nextest. It may also suit teams looking to add mutation checks to CI.
Verdict
cargo-mutants offers Rust teams a way to check whether tests catch selected code changes, with options for CI and incremental analysis. Its Cargo-only build support and host-platform requirement are important constraints.
The facts
Each one read from cargo-mutants's own pages, with the date it was checked.
What it does
- Build system limit
- Build tools other than Cargo are not currently supported.checked 5 Oct 2026
- CI
- The manual includes instructions and examples for testing mutants in CI, including incremental pull request testing and full development branch testing.checked 4 Oct 2026
- CI integration
- The project documents GitHub Actions workflows and says cargo-mutants emits structured annotations when it detects that it is running in an action.checked 5 Oct 2026
- Compatibility limit
- Cross-compilation is not currently supported, so the Rust tree must be buildable for the host platform.checked 4 Oct 2026
- Configuration
- Options can be configured in `.cargo/mutants.toml`, and the guide recommends checking that file into the source tree.checked 5 Oct 2026
- Dismiss findings
- Users can dismiss mutants with a `#[mutants::skip]` attribute or a configuration file.checked 4 Oct 2026
- Exclude mutations
- Items can be skipped with `#[mutants::skip]`, and specific mutations can be excluded with `#[mutants::exclude_re("pattern")]`.checked 5 Oct 2026
- Getting started
- You can run `cargo mutants` in a Rust source directory to identify functions that may be inadequately tested.checked 5 Oct 2026
- How to run
- Run `cargo mutants` in a Rust source directory to identify functions that may be inadequately tested.checked 4 Oct 2026
- Installation
- The guide documents installation with `cargo install --locked cargo-mutants`, `cargo binstall`, or binaries from GitHub releases.checked 5 Oct 2026
- License and warranty
- The project is MIT licensed and provided as-is with no warranty of any kind.checked 4 Oct 2026
- Maintenance
- The repository describes the project as semi-actively maintained in spare time as of August 2026, with bug reports and pull requests read at higher latency.checked 4 Oct 2026
- Purpose
- cargo-mutants is a mutation testing tool for Rust that finds places where bugs could be inserted without causing tests to fail.checked 5 Oct 2026
- Reproducibility
- Results should be reproducible when the build and test suite are deterministic.checked 4 Oct 2026
- Runtime
- A run’s duration depends roughly on the number of viable mutations multiplied by the time to run the test suite for each mutation.checked 5 Oct 2026
- Rust versions
- Building cargo-mutants requires a reasonably recent stable, nightly, or beta Rust toolchain.checked 4 Oct 2026
- Setup
- The tool requires no changes to the source tree or other setup before installation and use.checked 4 Oct 2026
- Support
- The project README invites users to share experience reports in GitHub Discussions and sponsor development.checked 5 Oct 2026
- Test requirements
- Useful results require reliable, non-flaky tests that run under `cargo test` or `cargo nextest`.checked 5 Oct 2026
- Test runners
- Useful results require reliable, non-flaky tests that run under `cargo test` or `cargo nextest`.checked 4 Oct 2026
Where it runs
- Platform limit
- Cross-compilation is not currently supported; the source tree must be buildable for the host platform.checked 5 Oct 2026
Alternatives to cargo-mutants
- 1
Mutatest
Free planOpen sourceAPILinuxmacOSSelf-hosted7.2Free plan - 2

ArcMutate
Free planLinuxmacOSSelf-hostedWindows6.7From $8 a month - 3
Mutant
Free planLinuxmacOS6.7From $250 a year - 4
MuJava
Free planLinuxmacOSWindows6.3Free plan - 5
pymute
Free planLinux6.3Free plan - 6
go-mutesting
Free planLinuxSelf-hosted6.2Free plan
