3 ms·
> With regards to the article's example, refactoring your code for unit tests is making life easier for the computer, not humans. I often find that writing pro
by laurent123456 10y ago
> With regards to the article's example, refactoring your code for unit tests is making life easier for the computer, not humans.
I often find that writing programs with testability in mind leads to more self-contained code, with less dependencies and cleaner interfaces. All this tends to make the code easier to reason about. I'd be curious to see an example of code that's good for unit testing but bad for humans.