4 ms·
This post makes the mistake of thinking that writing a bunch of tests will make everything better. In my experience, the only thing that will help you when it c
by freework 12y ago
This post makes the mistake of thinking that writing a bunch of tests will make everything better. In my experience, the only thing that will help you when it comes to expanding/fixing an existing codebase is knowin what the code is doing. When the app crashes and you look at the traceback, you need your brain to be able to understand why the program crashed. No matter how many tests fail or how many email alerts you get from travis-ci, your primary task is to understand what the code is doing.
- npsimons 12y agoAnd how do you know what the code is doing? One of the most effective ways I've found is to look at the tests. If there are none, even better: I can get a really good feel for how the system operates by writing tests, increasing coverage as I go. Tests aren't an end; they are a means to assuring proper function, but also towards understanding and writing better software (by forcing you to make code testable, which naturally leads to decoupling, etc).