My team has recently begun using Bob Martin’s Clean Code book and videos to improve our code’s readability. I’ve been completely blown away by how much easier it is to add unit tests to clean code.
I’ve been working through the Xcode project template code to add unit test to it. Trying to add unit tests to the unmodified, template generated boilerplate code is not easy. Some might say impossible or not worthwhile. However, once I started refactoring the code using Uncle Bob’s recommendations, the code magically became easy to unit test.
I highly recommend Clean Code. It will make your life easier.