Property Based Testing, By Example
summary
Demonstrates property-based tests for a menu-sorting example using QuickCheck family tools (jsverify for JavaScript, ScalaCheck on the JVM) that generate random records and reveal edge cases — an early failure shrinks to a single-space string showing a sorting bug on empty or tiny names. Shows generators for nested records, grouping-by-course implementation driven from failing properties, and practical tradeoffs: generator design takes time but yields many realistic failures and shrinking pinpoints minimal counterexamples.
AI-written summary · about
chapters (9)
- 0:00Introduction
- 1:49What is property based testing
- 6:01Tools and frameworks
- 12:34Generating random data
- 24:08Testing sorting logic
- 33:29Refactoring and grouping
- 45:01Properties in production
- 51:06When to use property based testing
- 52:10Q&A
related talks
36mProperty Based Testing: From Theory to Practice
13mIntroduction to Property Testing in Javascript
30mProperty Based Testing: From Theory to Practice
45mProperty based tests for the masses
58mProperty Based Testing: Concepts and Examples
51mProperty-Based Testing
51mProperty Testing: Write Fewer Tests, Find More Bugs
23mProperty based testing is a mindset
