I've written unit testings using xcode 4's built in framework before, and when I run them the process by default seems to be that the app launches and then the tests are run.
I've been moved on to a project that already has tons of unit tests, and I have recently added some of my own. In my unit tests I make a few calls to stuff in [UIApplication sharedInstance]. All of these tests fail because for some reason in this project the app does not open first, so UIApplication sharedInstance returns nil.
I'm assuming that because the default behavior is to have the app open, there has to be an option somewhere that has turned this off. I've been poking around in the scheme editor for a few minutes and can't get anything to make the app run. I've tried clicking the "run" checkbox under the build tab of the unittest scheme and had no success.
Edit: So when comparing a new project to this one, I've noticed that under Build Settings -> Unit Testing -> Test Host there is $(BUNDLE_LOADER) defined. I tried assigning that to the new project, and when I hit done it just magically disappears. No error or explanation of any kind.