If you're just starting out with testing your app logic, there are a couple of thoughts you might already have on the subject, or maybe none at all. To start testing your code, you don't need to have a computer science degree or spend days studying the absolute best way to test your code. In fact, chances are that you're already sort of testing your code and you don't even know it.
So, what does it really mean to test your code? That's exactly what we'll cover in this section. First, we'll look at testing code and the different types of test you might want to write. Then we'll dive into XCTest and setting up a test suite for an app. Finally, we're going to see how we can optimally test some real code and how we should refactor it to improve testability.