~/talk

Beyond Unit Tests: Taking Your Testing to the Next Level

Talkat PyCon 2018 · on Friday, 2018-05-11· [python, testing]

Uses property-based testing with Hypothesis to generate hundreds of inputs (and shrink failing cases) and uses dpcontracts runtime pre/postconditions to make functions self-checking. A generated test finds the max-product bug caused by negative numbers; a tail example gets a precise precondition/postcondition that detects invalid input and wrong output. Combining these techniques catches subtle edge cases, localizes bugs to the offending module, and verifies pure-function behavior (contracts are slower and intended for testing/development).

AI-written summary · about

  1. 0:00Intro
  2. 0:32Welcome
  3. 2:05What are Unit Tests
  4. 2:50Beyond Unit Tests
  5. 4:54Property Based Testing
  6. 8:05Catching Regressions
  7. 8:46Finding Good Properties
  8. 11:35Integration Testing
  9. 12:46MyPI
  10. 14:15Static Type
  11. 16:02Type Check Version
  12. 16:58Post Condition
  13. 17:56Contracts
  14. 20:11Property Tests
  15. 27:42Formal Methods
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.