2 ms·
What about when you are handling external data? Don't you test what will happen when unexpected types are received? How do you test the handling when a JSON key
by josephlord 12y ago
What about when you are handling external data? Don't you test what will happen when unexpected types are received? How do you test the handling when a JSON key you were expecting to be an array turns out to be a string or an integer or vice versa?
Do you handle nil's correctly in every place they might occur. These are all things that can be covered by a powerful type system (such as Swift's unless you overuse "!"[0]).
[0] Anything other than use for a member that is initialised during the init method is a code smell in my view.