ios - Appium - iOS - 写入 xctestrun 文件时出错:错误域 = NSCocoaErrorDomain 代码 = 4
问题描述
我正在尝试将 Appium 1.12.1 连接到具有自动服务器的物理 iOS 设备。这些是我正在尝试的功能:
{
"browserName": "Safari",
"platformName": "iOS",
"platformVersion": "12.1",
"deviceName": "iPhone 6",
"automationName": "XCUITest",
"startIWDP": true,
"udid": "auto"
}
我收到一个冗长的错误,开头是:
An unknown server-side error occurred while processing the command. Original error: Unable to launch WebDriverAgent because of xcodebuild failure: "xcodebuild failed with code 65 xcodebuild error message: 2019-04-09 10:14:08.626 xcodebuild[22198:212737] Error writing xctestrun file: Error Domain=NSCocoaErrorDomain Code=4 "The folder “WebDriverAgentRunner_iphoneos12.2-arm64.xctestrun” doesn’t exist."
解决方案
我有同样的问题。在“/Users/YOUR_NAME/Library/Developer/Xcode/DerivedData/”我有两个文件夹: WebDriverAgent-akxhdiizyykdxefsthlnfyomlaiz WebDriverAgent-ciegwgvxzxdrqthilmrmczmqvrgu
Appium 尝试从 WebDriverAgent-akxhdiizyykdxefsthlnfyomlaiz 获取文件夹,但需要 WebDriverAgent-ciegwgvxzxdrqthilmrmczmqvrgu。我从 WebDriverAgent-ciegwgvxzxdrqthilmrmczmqvrgu 复制到 WebDriverAgent-akxhdiizyykdxefsthlnfyomlaiz,现在一切正常。
推荐阅读
- automation - 如何在空手道请求的 URL 参数中使用响应中的参数
- android - 通过绝对文件路径使用 Intent 打开图像
- r - 在 Shiny 中返回多个对象
- azure - 在任务完成时重新分配 Azure VM
- react-native - 如何在 Expo React Native 中将 base64 转换为字节?
- facebook-graph-api - 即使我拥有 user_videos 权限,也无法访问 Facebook user/live_videos
- php - 如何强制服务器响应为 json
- java - 用户无权访问此对象。带储藏火库
- typescript - 无法使用 Typescript 和 Puppeteer 部署 firebase 功能
- javascript - 匹配用户算法