使用Jenkins运行ios-sim
我正在尝试使用ios-sim从命令行启动我的应用程序,但这是我得到的:
Started by user UserBuilding in workspace /Users/Shared/Jenkins/Home/jobs/UI Testing/workspace
[workspace] $ /bin/sh -xe /var/folders/h4/ws64t3bx2nnds4pg3345xrr000009c/T/hudson6341279754557259451.sh
+ /Users/myUser/Desktop/ios-sim launch /Users/Shared/Jenkins/Home/jobs/Project_Monkey_Build/workspace/build/Debug-iphonesimulator/ProjectMonkey.app
[DEBUG] Could not start simulator session: Error Domain=DTiPhoneSimulatorErrorDomain Code=5
"Operation failed with underlying error 4294956486." UserInfo=0x1001b1760
{NSLocalizedDescription=Operation failed with underlying error 4294956486.,
NSUnderlyingError=0x1001a3390 "The operation couldn’t be completed. (OSStatus error -10810.)"}
看起来像是权限问题,因为我可以从终端运行相同的命令,并且工作正常。我还尝试将777权限授予ios-sim和MonkeyTalk目录,但仍然没有。
任何想法?
回答:
这可能与Jenkins流程没有“显示”有关。尝试以登录到桌面的用户身份运行Jenkins,然后再次运行ios-sim。
从启动卸载Jenkins:
sudo launchctl unload /Library/LaunchDaemons/org.jenkins-ci.plist
然后从终端运行Jenkins:
sudo su jenkins -c "JENKINS_HOME=/Users/Shared/Jenkins/Home /Library/Application\ Support/Jenkins/jenkins-runner.sh"
如果可行,您可以通过将启动的作业配置文件从/Library/LaunchDaemons/org.jenkins-
ci.plist移至来使Jenkins始终以登录用户身份运行。~/Library/LaunchAgents/org.jenkins-ci.plist
以上是 使用Jenkins运行ios-sim 的全部内容, 来源链接: utcz.com/qa/405216.html