Mutmut – Python Mutation Tester
Published on: 2025-06-20 14:38:46
mutmut - python mutation tester
Mutmut is a mutation testing system for Python, with a strong focus on ease of use. If you don't know what mutation testing is try starting with this article.
Some highlight features:
Found mutants can be applied on disk with a simple command making it very easy to work with the results
Remembers work that has been done, so you can work incrementally
Knows which tests to execute, speeding up mutation testing
Interactive terminal based UI
Parallel and fast execution
If you want to mutate code outside of functions, you can try using mutmut 2, which has a different execution model than mutmut 3+.
Requirements
Mutmut must be run on a system with fork support. This means that if you want to run on windows, you must run inside WSL.
Install and run
You can get started with a simple:
pip install mutmut mutmut run
This will by run pytest on tests in the "tests" or "test" folder and it will try to figure out where the code to mutate is.
You can stop
... Read full article.