Categories
mobile Programming

Launching! iOS Unit Testing: Beyond the Model

I’m super excited to release something that I’ve been working on for a while.

Unit testing on iOS is… not common. And part of the problem is that people don’t know where to start. It can be overwhelming.

Building on my years of experience leading iOS apps with over 80% test coverage, including at Google, and my extensive experience in curriculum development and education, I’ve put together a workshop that takes you through the process step by step. It covers:

  • Writing unit tests on model classes.
  • Using mocks.
  • Unit-testing UI code (and how to test UIViewControllers!).
  • Writing your first UIAutomation tests.

The (MIT-licensed) sample code is ready to go (just check it out from GitHub) so you can focus on writing better tests, not wrangling dependencies.

It’s fully digital. Download the PDF, and work through. Email support included.

Who is this for? If you have iOS experience and you:

  • Haven’t written any tests and don’t know where to start, start at Section 1.
  • Are comfortable writing unit tests but want to better test your UI code, start at Section 2.

This isn’t designed for people without iOS experience looking to learn iOS.

Some nice things people have said already:

“Thanks so much… it’s helped me a lot. I have a fairly large, complex code base that I want to add tests to and the workshop has helped me to think about how to even begin to do that.”

—Cathy @catshive

“I really like the workshop. I like the format and pacing, how you’ve structured the Xcode project and using unfulfilled/failing tests for the participant to add themselves. I’ll definitely check out KIF for my own projects, even if it’s just as a way to ensure my apps are properly Accessible.”

Harry @inquisitivesoft

Buy it for 20 USD

Please note: this focuses on Obj-C not Swift, although the patterns should be applicable to Swift as well. I’m looking into a Swift version so let me know if that’s something you are interested in.

If you’re a student or underemployed, contact me and I’ll send you a discount code.

Thanks so much to the many people who tested, reviewed, and gave feedback.

16 replies on “Launching! iOS Unit Testing: Beyond the Model”

[…] you found this interesting, I’ve covered testing iOS apps in more detail in this workshop – there’s a sample app and a guide that takes you step by step through adding […]

[WORDPRESS HASHCASH] The comment’s server IP (69.163.242.185) doesn’t match the comment’s URL host IP (69.163.242.203) and so is spam.

+1 for a swift version

[WORDPRESS HASHCASH] The poster sent us ‘0 which is not a hashcash value.

Being that Swift is rapidly coming into the fore, I would like to have the Swift equivalent.

[WORDPRESS HASHCASH] The poster sent us ‘0 which is not a hashcash value.

[…] to do. To learn more about writing tests you might want to have a look at Cate Hudson’s iOS Unit Testing: Beyond the Model I’ve just bought it so I can’t say for sure that it’s useful but it looks very promising and […]

[WORDPRESS HASHCASH] The comment’s server IP (66.96.183.4) doesn’t match the comment’s URL host IP (66.96.149.32) and so is spam.

Comments are closed.