automated testing of optionals.

Discussion in 'iOS Programming' started by 1458279, Jan 8, 2016.

  1. 1458279 Suspended

    1458279

    Joined:
    May 1, 2010
    Location:
    California
    #1
    Is there a way in Xcode to test a program and have all the optionals not unwrap?

    It seems that some optionals will be hit or miss, how do you test all the optionals in a program so you can account for all the nil conditions in an automated way?
     
  2. PhoneyDeveloper macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
    #2
    Presumably you have to mock the methods that could return nils. Don't really know how to do that though.
     

Share This Page