#1 楼 @yzx200712256 想依照 group 配置,method 太多了
不错的落地方式,可以搞个 mock 平台,平台上直接 hook response 的,展示后端返回数据,用户可以可视化的修改 response,再返回。 更屌啦
找到原因了:
public void swipe(int startx, int starty, int endx, int endy, int duration)
endx 所传参数应该是增量
endy 所传参数应该是增量
[HTTP] --> POST /wd/hub/session/97559adb-a894-40d2-9f87-7341aac8d530/touch/perform {"actions":[{"action":"press","options":{"x":187,"y":517}},{"action":"wait","options":{"ms":300}},{"action":"moveTo","options":{"x":187,"y":50}},{"action":"release","options":{}}]}
[MJSONWP] Calling AppiumDriver.performTouch() with args: [[{"action":"press","option...
[debug] [XCUITest] Executing command 'performTouch'
[JSONWP Proxy] Proxying [POST /uiaTarget/0/dragfromtoforduration] to [POST http://localhost:8100/session/70E712D5-44E1-447B-826F-86A460A555C7/uiaTarget/0/dragfromtoforduration] with body: {"fromX":187,"fromY":517,"toX":374,"toY":567,"duration":0.3}
#59 楼 @dengwei729
尝试用 swipe 方法来做:
/wd/hub/session/a07d8685-4109-48b9-8185-337da0f75c81/touch/perform {"actions":[{"action":"press","options":{"x":192,"y":467}},{"action":"wait","options":{"ms":100}},{"action":"moveTo","options":{"x":182,"y":50}},{"action":"release","options":{}}]}
大家对滑动的操作,有什么见解:
在 ios10 上,使用 scrollTo 方法,结果悲剧了,appium 太贱了
自己拼的请求,报错
[JSONWP Proxy] Proxying [POST /element] to [POST http://localhost:8100/session/C4636841-6E75-4181-B828-09972EEB43CC/element] with body: {"using":"class name","value":"XCUIElementTypeTableView"}
[JSONWP Proxy] Got response with status 200: {"value":"Invalid argument for class used 'XCUIElementTypeTableView'. Did you mean XCUIElementTypeXCUIElementTypeTableView?","sessionId":"C4636841-6E75-4181-B828-09972EEB43CC","status":15}
#52 楼 @Lihuazhang 是的,现在 ios10 市场占有率很高了,稳定性测试需要兼容它了
#98 楼 @chenhengjie123 是想着自动化把 monkey 跑起来,你们 monkey 流程是啥? 模拟器支持多开么?
话说现在升级到 ios10 了,大家稳定性测试怎么做的呢?
模拟器如何安装包呢?
#39 楼 @Lihuazhang 官网没有找到,帮忙找找呗
@seveniruby @Lihuazhang 出了 xcode8 后,UIAutomation api 查询地址,俩位能找到么?
dengweideMacBook-Pro:runScripts dengwei$ /usr/bin/instruments -w 00e630def672da63ed0bae762c3d78aebb67ea8d -t /Applications/xcode7/Xcode.app/Contents/Developer/../Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.xrplugin/Contents/Resources/Automation.tracetemplate /Users/dengwei/Documents/ios_auto/test.app -e UIASCRIPT /Users/dengwei/Documents/ios_auto/src/cases/search/aroundSearch/TC_P1_1611007.js -e UIARESULTSPATH /Users/dengwei/Documents/ios_auto/output -v
2016-09-19 10:05:58.392 instruments[452:3696] WebKit Threading Violation - initial use of WebKit from a secondary thread.
dengweideMacBook-Pro:runScripts dengwei$
xcode7 在 ios10 设备上,command 执行脚本,没有任何报错,大家遇到过么? 有什么法子么
#4 楼 @zuiniao123 我这边自动化是直接用的 UIautomation , appium1.6 直接 xcuitest,我查一下
UIAutomation 不能用了,大家公司切走了么, appium 应该也不能用了
#2 楼 @chenhengjie123 问题现象已更新,谢谢提醒