Skip to content
SPECIFICTION
Get listed

Infection vs mutmut

Infection

infection.github.io

mutmut

mutmut.readthedocs.io

Side by side

FigureInfectionmutmut
Price from——
Free plan——
Free trial——
Open source——
WebYes—
Windows—Yes
macOSYesYes
LinuxYesYes
Self-hosted—Yes
Plans published00
Spec score · Mutation Testing Tools7.6 (#11)7.2 (#16)
DistributionThe recommended PHAR distribution bundles PHPUnit, PhpSpec, Codeception and Testo, and the PHAR signature can be verified with the documented GPG key.The PyPI listing shows mutmut version 3.8.0, released September 12, 2026.
LicenseThe project is released under the BSD-3-Clause License.The package is distributed under the BSD-3-Clause license.
Parallel executionTests for mutated code can run in parallel with the --threads option, including automatic CPU-core detection with --threads=max.The project lists parallel and fast execution as features.
PurposeInfection mutates PHP source code and reports changes that a test suite fails to catch.mutmut is a mutation testing system for Python focused on ease of use.

In their own words

Infection

Infection is a PHP mutation-testing library that shows which changes a test suite fails to detect. It creates mutants using predefined operators, runs tests against changed code, and records killed and escaped mutants, errors, and timeouts. Its Mutation Score Indicator measures the share of generated mutations detected by tests; it also reports Mutation Code Coverage and Covered Code Mutation Score Indicator. Infection supports PHPUnit, PhpSpec, Codeception, and Testo, and runs from the command line at a project root. Teams can run mutated tests in parallel, focus analysis on touched lines or files, and set minimum mutation-score thresholds that fail a build. The homepage describes more than 100 mutators grouped into profiles and allows custom mutators. Optional PHPStan and Mago integrations can help catch escaped mutants involving type violations, dead code, and unreachable paths. Installation options include PHAR, Phive, Composer, Git, and Homebrew. A browser playground supports trying PHP code and tests without installing the tools. Infection is free under the BSD-3-Clause license and requires PHP 8.3 or newer plus Xdebug, phpdbg, or pcov.

Visit infection.github.io

mutmut

mutmut is a free, open-source mutation testing system for Python. It makes small code changes called mutants so developers can check whether tests detect them. Its listed operators increment integer literals by one, change < to <=, and swap break and continue. The project supports pytest and remembers completed work for incremental runs, selecting tests to run for each mutant. An interactive terminal interface lets users browse mutants, write one to disk, and rerun individual cases after adding tests. Runs are described as parallel; configured coverage.py can restrict mutations to covered lines. The documentation also supports filtering with mypy or pyrefly, but not pyright or ty. For CI/CD, mutmut can export statistics and generate mutation-score badge JSON for a Shields endpoint. Configuration in setup.cfg or pyproject.toml can specify source paths and pytest selection arguments. It requires Python 3.10 or later and a system with fork support, so Windows users need WSL. Version 3 and later mutate code inside functions; version 2 uses a different model for code outside functions. The package is licensed under BSD-3-Clause.

Visit mutmut.readthedocs.io