问题
I am trying to double tap
an element in IOS Simulator using appium but unable to do so.
Methods tried:
action.tap(x=xx, y=yy, count=1).release().perform()
2 times in a row,but it seems there is a 2 second gap which in real world would not be a double tap
element.click
same problem as above
action.press(x=xx, y=yy).wait(500).release().perform().press(x=0, y=0).wait(500).perform()
no result
action.tap(x=xx, y=yy, count=2).release().perform()
no result.
Is there any thing else i can try or any other method which works on ios
.
回答1:
I call it in a similar way the first method you listed, its not as fast as double tap, but its less than one second delay
Appium::TouchAction.new.tap(x: xx, y: yy, count: 2).perform
.tap
dont need to use release
, only .press
need it
回答2:
You should do both of the press commands before calling perform()
:
action.press(x=xx, y=yy).release().wait(500).press(x=xx, y=yy).release().perform()
来源:https://stackoverflow.com/questions/38791731/double-tap-in-ios-simulator-not-working