Blog

Is test-driven development still relevant?

Sept. 2, 2026

It's been exactly a year since I went all-in with AI-assisted coding. Does that mean that test-driven development isn't relevant anymore?

Why do I hate the testing pyramid?

Aug. 17, 2026

Every book you'll read or talk you'll watch, will tell you that your tests should follow the testing pyramid. If it's not a pyramid, it's a honeycomb, a trophy, or some other shape. It's not that I don't like shapes per se. But I think that all these shapes reverse the cause and consequence.

How to test custom middleware in FastAPI?

July 29, 2026

Sooner or later, you need to add custom middleware to your FastAPI app. Once we have it, we'd like to test it. The question is how to do that efficiently.

Testing is boring - why do I care about it so much?

July 6, 2026

Automated testing is boring to software engineers. Everyone would like to build something that's more complex, feature-rich, or faster. So why do I care about it so much?

Why most Python tests are a waste of time?

March 31, 2026

Cheatsheet

Most Python test suites have the same problem: they cost more trouble than they save. CI jobs that take forever, tests that break on every refactor, flaky pipelines you keep restarting. After years of writing (and deleting) tests, I've landed on 7 qualities that separate tests worth keeping from tests that just slow you down.

Mock HTTP Calls Effortlessly in Python with responses

Jan. 7, 2026

A utility for mocking Python's requests library in tests, helping avoid real network traffic during testing.

Time Travel in Your Tests with freezegun

Nov. 27, 2025

A library enabling developers to freeze time in tests for reliable validation of subscription status, trial eligibility, and date calculations.

How to mock different return values for each call of a method

Oct. 14, 2025

Techniques for handling scenarios where identical methods need distinct behaviors across multiple invocations.

How to customize assertion error message

Sept. 16, 2025

Methods for improving test failure clarity through custom error messaging.

Name parameterized pytest examples

April 3, 2025

Guidance on maintaining readability when using pytest parametrization with numerous examples.