简体   繁体   中英

xcodebuild equivalent of Xcode's “Product > Build For > Testing”

I'm trying to write a script that submits iOS apps to AppThwack (a 'real device' UI testing service). Their guidance is to use the Xcode GUI and build the app using the Build For > Testing option in the Xcode Product menu. This works, but I haven't been able to translate this into the xcodebuild equivalent.

More generally, how do we determine what arguments Xcode is passing to xcodebuild (assuming it uses that tool).

This is now possible as of Xcode 8 (in beta at time of writing). Use build-for-testing .

Example:

xcodebuild -workspace <workspace> -scheme <scheme> -destination 'generic/platform=iOS' build-for-testing

To switch to a beta version of xcodebuild, use xcode-select :

sudo xcode-select -switch /Applications/Xcode-beta.app/Contents/Developer

xctool has a flag called build-tests that will do just that.

(As of this post, it is not currently Xcode 7 compatible, but they are working on it.)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM