Hacker News new | past | comments | ask | show | jobs | submit login

Sure there is, 3 reasons:

1) No one writes unit tests for old code until it breaks the first time, because they're too busy working on new stuff.

2) No one gets assigned to write unit tests for old code until it breaks the first time, because there's always more work to do than you have time to do it in and if its not broken, its not hurting anyone enough to get resources and time diverted to it

3) Even if you write a mess of unit tests for stuff, it's always possible to miss unit testing a specific scenario. 100% line and branch coverage is not 100% bad outcomes or 100% possible inputs.

I've never worked anywhere that had 100% of their code tested with automated tests around 100% of the possible inputs and outputs. And the older the code and the longer it had been running stably, the less likely it was to have that testing if the testing wasn't written with the code. Like everything else in development, tests add up in the technical debt pile too.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: