Ios – A build only device cannot be used to run this target

iosxcode

I get this error when I trying to test an app.

A build only device cannot be used to run this target.

No supported iOS devices are available. Connect a device to run your application or choose a simulated device as the destination.

Best Answer

add -destination 'platform=iOS Simulator,name=iPhone 6,OS=9.3' to your xcodebuild