Skip to content
Testing & Debugging
-
Testing & Debugging
Unit Testing Basics: First Tests and Failing Diffs
Write your first Python unittest file, find edge cases at boundaries, read real failure diffs, run doctest and Dart test offline, and time 10,000 tests.
-
Testing & Debugging
Test Doubles in Python: Mocks, Fakes, Fixtures
Stub, fake, mock and spy, run for real: the wrong patch target, autospec catching a bad signature, leaky fixtures, and a mock that hid two bugs.
-
Testing & Debugging
How to Read Error Messages and Stack Traces
Real tracebacks from Python, PHP, JS, Java, Dart, Swift and C read line by line: which frame is yours, what Caused by means, and how to search an error.
-
Testing & Debugging
git bisect run: Find the Commit That Broke It
Find a regression in 64 commits with git bisect run: 8 script runs instead of 41, exit 125 for unbuildable commits, and a 1 ms to 613 ms slowdown.
-
Testing & Debugging
Flaky Tests: Clocks, Seeds, Test Order and Threads
Make five kinds of flaky Python tests fail on purpose, measure each failure rate (8% to 70%), then fix them with UTC clocks, seeds, cleanup, locks and events.
-
Testing & Debugging
Debugging with print, Logging and a Debugger
When to use print, logging or a debugger: a real pdb session, post-mortem, lldb on a C crash, rubber-duck and minimal repro, and what logging costs.
↑