as a beginner i thought tests were for finding bugs.
the feature works, so ship it. why write more code to check code that already runs.
then one day i fixed a small bug in one place and broke something completely unrelated somewhere else. i did not even notice for a while.
the reason is the part worth keeping. the thing i broke was not in the code i was looking at. it was code that was already working, that i had no reason to open and no reason to click through after my change. so nothing told me. a test sitting on that other piece would have failed the second i saved the file.
so tests are not for finding bugs today. the code already works today, that is why it shipped. they protect that working code from what future-me does to it months later.
extract a string, rename a function, refactor a flow. every one of those is a change to code that is currently fine.
i used to see tests as extra work on top of a finished feature. now they are the thing that lets me change my own code without being scared of it.

day 3 — without tests vs with tests
#buildinpublic #softwareengineering #startup #maahitatechnologies