目前就想点击某个坐标

self.driver.tap([(500, 500)])

可是 case 挂了,error 如下

Traceback (most recent call last):
  File "ape_other_shoplists.py", line 84, in test_03_branches_shoplist
    self.driver.tap([(500, 500)])
  File "/Library/Python/2.7/site-packages/appium/webdriver/webdriver.py", line 206, in tap
    action.perform()
  File "/Library/Python/2.7/site-packages/appium/webdriver/common/touch_action.py", line 94, in perform
    self._driver.execute(Command.TOUCH_ACTION, params)
  File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 175, in execute
    self.error_handler.check_response(response)
  File "/Library/Python/2.7/site-packages/appium/webdriver/errorhandler.py", line 29, in check_response
    raise wde
WebDriverException: Message:

Appium server capabilities 设置就这里比较特别,其他很正常

desired_caps['automationName'] = 'Selendroid'

请问发生了什么?如何才能在 android 端点击个坐标?

appium log 已经贴评论里了,目前我暂时先用 adb shell input tap 代替操作的

os.popen('adb -s {0} shell input tap {1} {2}'.format(self.device_id, x, y))


↙↙↙阅读原文可查看相关链接,并与作者交流