Stop Writing Tests!
summary
Argues that instead of hand-crafting example inputs, use property-based testing with Hypothesis to assert invariants (sorted order + same multiset via collections.Counter) and let the library generate cases; shows Hypothesis Ghostwriter that auto-produces tests (including idempotence and round‑trip checks). Demonstrates coverage‑guided fuzzing with atheris and the pure‑Python hyperfuzz to run many tests concurrently, finds real bugs (JSON nan/infinity edge cases, ast.unparse absence, an invalid‑input crash in Black), and recommends migrating tests incrementally.
AI-written summary · about
chapters (10)
- 0:00Introduction
- 1:17What testing really means
- 3:00Limitations of traditional testing
- 5:07Property-based testing
- 7:14Three-step plan for Hypothesis
- 9:17Round-trip property tests for persistence
- 12:28Migrating tests to property-based
- 14:55Coverage-guided fuzzing with Hypothesis
- 16:17Live demo of HypoFuzz
- 17:00Summary and call to action








