我一直在尝试使用Appium运行自动化测试,它们已经在物理设备中运行,但是出现错误:[WD Proxy]得到了意外的响应:{“ value”:{“ error”:“ session未创建”,“消息”:“必须具有“功能”才能创建新会话”}
我已经阅读了配置指南,并且webDriverAgent似乎在设备中正确运行,当我向在设备上运行的webdriveragent请求时,得到响应:
[WD Proxy] Determined that the downstream protocol for proxy is W3C
[XCUITest] WebDriverAgent information:
[XCUITest] {
[XCUITest] "message": "WebDriverAgent is ready to accept commands",
[XCUITest] "state": "success",
但是,当Appium发出创建新WDA会话的请求时,会收到以下响应:
[WD Proxy] Got an unexpected response: {"value":{"error":"session not created","message":"'capabilities' is mandatory to create a new session"},"sessionId":"595F87C8-0564-4B75-94B4-7D67BA0AF382"}
使用这些功能
'app': app,
'bundleId' : bundle_id,
'platformName': platform_name,
'automationName': automation_name,
'platformVersion': platform_version,
'deviceName': device_name,
'udid': udid,
'xcodeOrgId': xcode_org_id,
'xcodeSigningId': xcode_signing_id,
'newCommandTimeout': new_command_timeout,
'updatedWDABundleId': updated_WDA_Bundle_Id,
'agentPath': "/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj",
'bootstrapPath': "/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent"
还有其他我可能会想念的东西吗?
答案 0 :(得分:0)
不确定是否确实需要这些功能:
link: {
display: 'flex',
flexDirection: 'row',
textDecoration: "none",
"&:hover, &:focus": {
backgroundColor: theme.palette.background.yellow
}
},
尝试删除它们,在我的测试中我也注意到,每次从真实设备切换到模拟器时,有必要重新启动appium服务器。
希望有帮助