Appium: Question: Separating press and release action for iOS

Created on 18 May 2020  路  1Comment  路  Source: appium/appium

touch_action = TouchAction(driver)
touch_action.press(x=10, y=10).perform() # line 2
...(pressing now...)
touch_action.release().perform() # line 4

This code works fine on Android(UIAutomator2).
But on iOS(XCUITest), released right after line 2. And error occurred on line 4.
Is it not possible on iOS?

Of course

touch_action.press(x=10, y=10).wait(1000).release().perform()

works fine both Android and iOS.

Thanks.

Question

Most helpful comment

Is it not possible on iOS?

No, such gesture won't work on iOS, because this is the way XCTest "understands" gestures.

See
https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/ios/actions.md
https://github.com/appium/appium/tree/master/docs/en/writing-running-appium/android/actions.md
for more details.

Please use Appium forum to ask questions

>All comments

Is it not possible on iOS?

No, such gesture won't work on iOS, because this is the way XCTest "understands" gestures.

See
https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/ios/actions.md
https://github.com/appium/appium/tree/master/docs/en/writing-running-appium/android/actions.md
for more details.

Please use Appium forum to ask questions

Was this page helpful?
0 / 5 - 0 ratings