This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Swipe { | |
// This method will get called in all the swipe methods because appium has depricated the swipe method in appium 1.9.1 | |
public static void swipe(int fromX,int fromY,int toX,int toY) { | |
TouchAction action = new TouchAction(driver); | |
action.press(PointOption.point(fromX,fromY)) | |
.waitAction(new WaitOptions().withDuration(Duration.ofMillis(600))) //you can change wait durations as per your requirement | |
.moveTo(PointOption.point(toX, toY)) | |
.release() |