2017-09-11 88 views
0

我在开发中使用了Xcode 9.0和iPhone 7。 在我.travis.yml我说:为什么Travis无法运行我的测试?

language: swift 
osx_image: xcode9 
script: 
- xcodebuild clean test -project BullsEye.xcodeproj -scheme BullsEye 
-destination "platform=iOS Simulator,name=iPhone 7,OS=11" CODE_SIGN_IDENTITY="" 
CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO -quiet 

但是当我在特拉维斯运行它,我得到这个:

The command "xcodebuild clean test -project BullsEye.xcodeproj -scheme BullsEye 
-destination "platform=iOS Simulator,name=iPhone 7,OS=11" CODE_SIGN_IDENTITY="" 
CODE_SIGNING_REQUIRED=NO ONLY_ACTIVE_ARCH=NO -quiet" exited with 70. 

66

我在Xcode中制定了我的方案Shared

这是什么问题,我该如何解决?

在日志中我也越来越:

Ineligible destinations for the "BullsEye" scheme: 
    { platform:iOS, id:dvtdevice-DVTiPhonePlaceholder-iphoneos:placeholder, name:Generic iOS Device } 
    { platform:iOS Simulator, id:dvtdevice-DVTiOSDeviceSimulatorPlaceholder-iphonesimulator:placeholder, name:Generic iOS Simulator Device } 

xcodebuild: error: Unable to find a destination matching the provided destination specifier: 
    { platform:iOS Simulator, OS:11, name:iPhone 7 } 
The requested device could not be found because no available devices matched the request. 
+0

你能分享一个链接到travis-ci.org上的完整日志吗?如果它是私密的,你可以在https://gist.github.com上复制/粘贴日志吗?谢谢! –

+0

@DominicJodoin https://travis-ci.org/orkhanalizade/BullsEye它在这里 –

回答

1

望着your latest build log,以下错误消息

xcodebuild: error: Unable to find a destination matching the provided destination specifier: 
    { platform:iOS Simulator, OS:11, name:iPhone 7 } 

似乎表明,你是不是使用有效的-destination值。我相信11不是OS的公认值。你可以用11.0代替吗?即-destination "platform=iOS Simulator,name=iPhone 7,OS=11.0"

我也提交了PR here

相关问题