testing

  • PSR-20 clocks, and the fake I stopped writing

    A clock interface written by hand in four projects, each slightly different, replaced by the standard one. One method returning a DateTimeImmutable is a small enough interface that…

  • The font library, and the licences nobody had checked

    6.5 in April, fonts become something an editor can install, and a site with eleven web fonts of which four are loaded and unused.

  • terraform test, on a module with no tests

    A module used by four environments and verified by applying it and looking at the console. The tagging assertion is the one that earns its place immediately, because…

  • Sampling a generated diff, and what sample size means

    An automated refactor across four hundred files, and a review that cannot read eight thousand lines. Splitting the run by rule and reviewing each separately is what makes…

  • A vendored file with a licence header and a test

    Copying two hundred lines out of a dependency, and the three things that make that legitimate rather than theft. The licence file, the upstream commit hash and the…

  • A design token pipeline that outlived its designer

    A token pipeline built in 2022 and the person who understood it has left. A colour change that took three days and touched five files.

  • Contract tests owned by the consumer, not by us

    Our tests asserting what our API returns, which proves nothing about what a consumer depends on. Owning the tests ourselves means asserting what we intended, and the whole…

  • A no-JavaScript assertion in a browser test

    A page whose interactive parts were converted to a directive-based runtime, and an assertion that it still works with scripting disabled. Progressive enhancement is a claim and this…

  • A framework upgrade that was mostly deleting

    Laravel 11 in March, a skeleton with four fewer directories, and an application still carrying 2019’s structure.

  • The test that asserted the middleware order

    A framework upgrade that moved middleware registration from an array to a fluent configuration, where the order is no longer visible in one place. The order matters —…