~/talk

Unit Testing Data with Marbles

Talkat PyData NYC 2018 · 2018-10-11..10-12· [testing, developer-experience]
links:none on file
links:none on file
slides:none on file

Argues that data needs executable assumptions and shows Two Sigma’s open‑source Marbles extending Python unit tests to capture local variables, add semantic assertions, and log every assertion as JSON (Elasticsearch‑friendly). Demonstrates with bike‑share CSVs and pandas, catching unexpected cases like trips longer than 10k or a marathon and month‑long rides. Provides notes on why a test exists, what to do, and time‑series of past failures so tests stay actionable; the system runs with existing unittest suites and CI.

AI-written summary · about

  1. 0:00Data assumptions matter
  2. 4:33Capturing assumptions in tests
  3. 9:30Turning assumptions into tests
  4. 13:59Testing real bike share data
  5. 17:57Context loss in failures
  6. 23:14Marbles for richer failures
  7. 26:05Semantic assertions
  8. 30:10Preserving test context
  9. 34:18Marbles for unit tests
  10. 35:45Documentation and resources
  11. 37:21Q&A
~/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.