XCTest, Failed to load test bundle. Crash on test launch XCTest, Failed to load test bundle. Crash on test launch xcode xcode

XCTest, Failed to load test bundle. Crash on test launch


Make sure iOS Deployment target fields of your application target and test target are the same


I had the same issue. Simply building and running the associated application target on an iOS11.1 simulator (which happens to match the "iOS Deployment Target" of Test target) it started working.

It seems starting the test the first time did not trigger a build of the test host. Subsequent runs seem to trigger the builds as needed and all is good.

YMMV


It happened to me when updating the Xcode version from 9.3 to 10. In my case, deleted the DerivedData, then the unit test works.