Modern and high-quality iOS applications are expected to perform flawlessly. An important input to ensuring flawless, regression-resistant code is to add comprehensive unit and integration testing as part of the development process. This article steps through a methodology for building repeatable, automated database unit tests for iOS applications using CoreData as their persistence layer.
Having a built-in relational database in iOS via CoreData is a pretty nice feature of the mobile OS. I’ve always liked using it, but like many developers I’ve never appreciated the volume of boilerplate code to create and maintain just to setup the basic scaffolding in a new project.