Process

8 min read

A year of writing the test first, honestly

Twelve months of test-first development on real projects: where it helped, where it slowed me down, and what I kept.

I resisted writing the test first for a decade. Last year I tried it on everything for twelve months, and I kept a diary.

Where it helped

Small, well-understood functions and every bug fix. Writing the failing test first for a bug means I know I have really fixed it.

Where it did not

Anything exploratory. When I do not yet know what the code should do, a test is a guess written in advance, and I end up rewriting both.

What I kept

Test first for bug fixes and libraries. Test after for prototypes, then throw the prototype away. It is less pure than I hoped and it works.

Written by

Iri Halvorsen, software engineer in Bergen

mail iri

Found a bug in my thinking? Tell me.

$ subscribe --notes

New notes by email, when there are any. About one a month.

Iri Halvorsen

Software engineer

Bergen, Norway

Open to work from January 2027

Colophon

Set in Geist and Geist Mono

Built in Framer

No tracking, no cookie banner

buildlog_

© 2026 Iri Halvorsen. All demo work is fictional.

exit 0

Create a free website with Framer, the website builder loved by startups, designers and agencies.