We do have troubles getting our CI to work with Xcode. We encounter the issue Could not determine bundle identifier for xxxTest TEST_HOST: some path that does not exist
One reason to have this error is that your info.plist of your target is not in its path. So if you moved it or removed the reference to it, you may get this error.
So if you moved it, put it back into its place or path. if you removed the reference to it, add it again, close and reopen the project.
In my app I found a solution.
The problem was of course in the test target.
I hope that this solution will work for you too. Go to your test target build settings.
Search for test host.
In my case this testHost was looking like
build/{buildConfigurationName}-iphoneos/{schemeName}.app/{appName}
Which is wrong as the actual path must be
build/{buildConfigurationName}-iphoneos/{schemeName}.app/{schemeName}
so if you have a build configuration called Alpha, in your app named MyApp, with a scheme called MyApp-Alpha the test host path should be
build/Alpha-iphoneos/MyApp-Alpha.app/MyApp-Alpha
it was
build/Alpha-iphoneos/MyApp-Alpha.app/MyApp
I hope this can help... unfortunately this issue appears in many cases.
So after ages of having this issue, we could find the right checkbox to fix this issue.
It somehow sounds weird but the issue was the configurations for the command-line builds inside of the Project settings.
I assume this happens because we always test against the debug configuration and it was set to release. Therefore it did the wrong build for the test host.
This does set the defaultConfigurationName
inside of the {projectname}.xcodeproject
.
Please comment if you have any more insights of this.