Note that there are some explanatory texts on larger screens.

plurals
  1. POXcode / iOS: Unit Tests, Schemes, and Configurations
    primarykey
    data
    text
    <p>My iOS project has five schemes: Local Development, Integration, QA, Demo, and Production. Each scheme uses a differing configuration to control things like network poll frequency, API endpoints, analytics, and so on.</p> <p>Similarly, we have five corresponding targets: Local Development, Integration, QA, Demo, and Production. Each target has several User-Defined Build Settings, which contain API keys, numeric values for timing, etc.</p> <p>Our application's <code>Info.plist</code> file uses application variables such as <code>${SOME_ENDPOINT_URL}</code> to draw in the corresponding User-Defined Build Settings.</p> <p>To retrieve the variables, I do something like the following:</p> <pre><code>[[[NSBundle mainBundle] infoDictionary] valueForKey:@"Some Endpoint URL"] </code></pre> <p>That would correspond to the User-Defined Build Setting, like this:</p> <pre><code>"Some Endpoint URL" = ${SOME_ENDPOINT_URL} </code></pre> <p>I am now looking at how to configure the project appropriately to perform unit and logic tests.</p> <p>To build out the tests to determine if the environments are configured correctly, I'm not certain what the best practice is.</p> <ul> <li>Is it correct to build out five additional Test-specific targets for each environment?</li> <li>Or is it better to override the "Run action's arguments" setting for the test component for each scheme, and provide something like an argument to specify which scheme we are looking at?</li> <li>Are there any existing references for configuring unit and logic tests for iOS projects with multiple environments? This project's complexity seems to exceed the scope of most documentation.</li> </ul>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload