Property-Based Testing
← Back to Advanced Testing Techniques
Generate random inputs, verify properties hold for all of them. Instead of testing specific examples, define properties that should always be true (Hypothesis for Python, QuickCheck for Haskell, fast-check for JS). Discovers edge cases humans would not think of.
Key Properties
Related
- Parameterized Tests (manual version)
- Fuzzing (related random testing)