Cannot unit-test framework with Xcode 8 on iOS 8.4 simulator

Originator:bcriscuolo
Number:rdar://28095069 Date Originated:08/31/16
Status:Open Resolved:
Product:Developer Tools Product Version:Xcode Version 8.0 beta 6 (8S201h)
Classification: Reproducible:Always
 
Summary:
On Xcode 8 beta 6, it is impossible to unit test an iOS framework on iOS 8.4 simulators. The reason for this is that the deployment target for XCTest’s host app appears to be iOS 9 — which means it cannot be installed on an 8.4 simulator. Therefore, the library cannot be unit tested in this configuration

Steps to Reproduce:
Steps to Reproduce:
0. Ensure you have an iOS 8.4 simulator runtime installed for Xcode, and a simulator set up for that runtime.
1. Create a new Xcode project and select “Cocoa Touch Framework” as the template; make sure that “Include unit tests” is checked.
2. Select the framework target in the file navigator and set the deployment target to iOS 8.4.
3. Select an iOS 8.4 simulator as the run destination of the default scheme and run the unit tests.


Expected Results:
The tests run and succeed because they are just the template tests that don’t do anything.

Actual Results:
Xcode does not run the tests at all and shows a dialog with the following error message (iPhone 5s 8.4 selected as the target simulator):

“iPhone 5s cannot run xctest.

iPhone 5s runs iOS 8.4, which is lower than xctest's minimum deployment target. Change your project's minimum deployment target or upgrade iPhone 5s's version of iOS."


Version:
Xcode Version 8.0 beta 6 (8S201h)
iOS 8.4 simulator

Notes:


Configuration:

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!