Test-Driven Development: Does it work for iOS apps?
Short answer: Sure! Here’s an example:
Yeah, that’s a really old image, and no, you can’t find this on the App Store anymore. But this was an app published by eBay. Here’s the unit test coverage:
It was written almost entirely using TDD. Sometimes tests weren’t written first (especially the code written by someone I couldn’t mentor because I was away). But test first or test last, they got written.
“That’s fine,” you may say, “but what benefit did they have?” If you’ve never done TDD, you haven’t felt the empowerment it brings:
Better design. Cleaner implementation. Think about it.
A bit more about that 92%:
iOS Test-Driven Development isn’t a pipe dream. I continue to use TDD, these days on an app for a Fortune 100 company. It’s my daily reality, and it can become yours.Learn About my TDD Workshop
Question: Have you used TDD to develop your apps, or any part of your apps? What were the ups & downs you experienced? Leave a comment below.
Programming was fun when I was a kid. But working in Silicon Valley, I saw poor code lead to fear, with real human costs. Looking for ways to make my life better, I learned about Design Patterns, Refactoring, and Test-Driven Development (TDD). Programming became fun again! I've now been doing TDD in Apple environments for 18 years. I'm committed to software crafting as a discipline, hoping we can all reach greater effectiveness and joy.
Please log in again. The login page will open in a new tab. After logging in you can close it and return to this page.