This Swift test tutorial will teach you all about writing effective tests in Swift on the iOS platform. It consists of a whole set of lessons to lead you through the process of learning to become a top-notch test writer. This includes learning the basic terminology and what the differences are between unit, integration and functional tests as well as more advanced test topics such as leveling up your tests using a BDD-style approach. Much of the content here is based upon my experience writing tests for nearly 30 years. I began writing tests back in the 1990's using the SUnit test framework for Smalltalk and have continued this exercise throughout my career. Though I've been writing tests for nearly 20 years, my approach was altered significantly after reading "The Art of Unit Testing" by Roy Osherove in 2010. This tutorial is divided into several helpful sections:
- How to write tests like a boss
- How to level up your test writing with a BDD-style approach
- What is a unit test?
- What is an integration test?
- What is a functional test?
- What is code coverage?