You can watch this episode by subscribing to Cocoacasts Plus.

Mastering MVVM With Swift

Using Stubs for Better Unit Tests

Testing the DayViewViewModel struct isn't very different from testing the view models of the SettingsViewController class. The only tricky aspect is instantiating a DayViewViewModel instance in a unit test.

Cocoacasts Plus

Are you ready to step up your game?

Cocoacasts Plus helps Swift and Cocoa developers take their education serious without being overwhelmed.

Watch Every Tutorial for $10 per Month
Next Episode "A Few More Unit Tests"