11

当我尝试使用 UIAutomation 在设备上捕获 UI 输入时,它挂起并显示“正在启动捕获”。

1) I click on Profile in Xcode which
2) Starts up Instruments where I select Automation and click Profile
3) Which starts Instruments running.  In Scripts I select Add->Create which shows the record button at the bottom 
4) I click the record button and it hangs saying "Starting Capture" and doesn't record my UI input.

我的配置文件方案的构建配置是调试。

知道我缺少什么导致 UIAutomation 挂起吗?

4

3 回答 3

41

对于 iOS8 设备,还要确保在“设置”中启用了 UI 自动化。

设置 -> 开发人员 -> 启用 UI 自动化

于 2014-10-31T18:18:51.493 回答
16

弄清楚了。我希望这对其他人有帮助!

1)  Click on Profile in Xcode (or Cmd-I)
2)  In Instruments select Automation and click Profile
3)  Click Instruments Record button to stop the running of the app
4)  Click Scripts -> Add -> Create
5)  Click Record button at bottom of Instruments (which is for recording the script)
6)  Click Record button at top of Instruments (which is for running the app)
7)  Click on Trace Log -> Script to view the script you are creating.

哇!

于 2013-03-16T00:05:26.867 回答
1

检查您是否在配置文件方案中选择了调试模式,并且您是否拥有正确的签名身份和配置文件。

于 2014-10-06T21:45:55.640 回答