2 ms·
> I distrust myself, and therefore I write basic unit tests which validate the code I've written to prove that I haven't screwed up. This drives me nuts. You
by bluefirebrand 2y ago
> I distrust myself, and therefore I write basic unit tests which validate the code I've written to prove that I haven't screwed up.
This drives me nuts.
You don't trust yourself to write code that isn't broken but you trust yourself to write quality tests that ensure the code isn't broken?
I don't understand this at all. Automated tests are just like any code, they are as prone to mistakes and bugs as anything else
- rectang 2y agoMy tests might of course be faulty, but statistically speaking adding some will reduce the number of bugs in the main code that get through. The tests don’t have to be perfect to have a positive impact; in fact my impression is that the lowest-effort tests have an outsized impact and a very high ROI.