Cannot run Swift XCTest project in AppCode


I have a workspace with three projects in it: One is a framework I develop, the other two are demo app projects, one in Swift and one in ObjC, both with UI test targets.

I can run all targets successfully in Xcode (app build, as well as App UI tests).

But in AppCode the Swift UI test build fails with:

Error running 'demo-swift-uitests': Product not found for target 'demo-swift-uitests' at /Users/user/Library/Caches/AppCode2017.2/DerivedData/myworkspace-etvinlgyceeawddgzehfltgwkrbx/Build/Products/Debug-iphonesimulator/


All other targets incl. Swift app build succeeds in Appcode. Can anyone help me to fix the issue to get the Swift UI test running in Appcode?

Official comment

Which AppCode version exactly are you using and what Xcode is selected in Preferences | Tools | Xcode? Could you please share a screenshot of demo-swift-uitests run configuration (from 'Edit Configurations'). Have you tried a clean build and clean AppCode's DerivedData for this specific project? Have you tried to recreate the same run configuration in AppCode from scratch - would it help?

Thanks Tatiana! I found out now what was wrong: The demo-swift-uitests config had the Build entry missing under the Before launch steps. Adding it fixed it. The objc config had it, the swift one for some reason not.


Please sign in to leave a comment.