【发布时间】:2012-05-15 18:35:24
【问题描述】:
我有一个 iOS 应用程序,我想把它放在持续集成中。我使用的策略是尝试从命令行运行测试。
我正在尝试使用以下脚本:
TRACETEMPLATE="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Instruments/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate"
instruments -t $TRACETEMPLATE build/Release-iphonesimulator/MyApp.app -e UIACSCRIPT "UnitTests/SomeTest.js"
SomeTest.js 是一个简单的 javascript 文件,我可以在 Xcode 中的 Instrumentation 中运行它并且它可以工作。我使用以下方式构建我的应用程序:
xcodebuild -alltargets -sdk iphonesimulator5.1
这会生成 MyApp.app。我可以在模拟器中从 Xcode 运行应用程序就好了,但是,当我尝试通过仪器运行时,我得到一个框,提示存在未知错误,并在命令行中打印:
2012-05-15 15:32:59.928 instruments[17548:1d03] Recording cancelled : At least one target failed to launch; aborting run
Instruments Trace Error : Failed to start trace.
谁能给我任何关于可能发生的事情以及我该如何解决这个问题的帮助/建议?
另外,它总是打开 iPad 模拟器?我可以让它打开我想要的任何模拟器吗?
【问题讨论】:
-
我也有同样的问题,也无法解决:(
-
到目前为止我找不到解决方案。我会尝试在苹果自己的论坛上询问,看看他们是否提出了一些建议。如果我发现了什么,我会告诉你的。
标签: ios continuous-integration ui-automation