What the Mutant? Using Mutator Testing to Write Better Tests
summary
Shows mutation testing as a way to verify tests by actually changing code and rerunning suites, using Stryker (JS/TS) and mutmut (Python); demonstrates a small checkout app where Stryker generates 28 mutants and a larger repo that creates 7,400 mutants and kills 4,300, with 1,400 survivors and ~22 minute baseline runs; recommends incremental runs, per-test configuration, and tightening assertions (exact values rather than loose checks) to convert surviving mutants into meaningful test fixes.
AI-written summary · about
chapters (12)
- 0:00Introduction
- 0:40Do You Really Write Tests?
- 2:30When AI Writes the Code and the Tests
- 2:55Why Coverage Isn't Enough
- 3:17What Is Mutation Testing?
- 4:44Stryker for JavaScript: Setup and Config
- 10:25Running Stryker: Weak Tests Exposed
- 12:57Writing Stronger Tests to Kill Mutants
- 14:38mutmut for Python
- 17:41A Practical Workflow with AI
- 19:03The Downsides of Mutation Testing
- 21:05Takeaways
