3 ms·
Defining the interface before you write the code is the major advantage of test-driven development and what it added to that way of thinking was very valuable e
by pcarolan 9y ago
Defining the interface before you write the code is the major advantage of test-driven development and what it added to that way of thinking was very valuable especially to novices. It also makes your code more modular and reusable. Writing code as if other people were going to use it is something we don't talk about enough.
- brango 9y agoI found it just flew in the face of iteration. I get something simple working, then iterate a few times, adding complexity. If you have to iterate your tests as well, you're just walking in treacle. Either that or you end up with a load of stuff in your interface that you thought you'd need, but when you actually got to it you either didn't, or it wasn't important to implement at the outset.