0

I have a piece of appium code (as below) which does the swipeup action on one android device using co-ordinates(using the coordinates as the element is non-responsive). Is there any way to make it dynamic so that it works on all screen sizes of different devices.

public void swipeToSend(){

            TouchAction swipe = new TouchAction(driver)
            .press(PointOption.point(489,2245))
            .waitAction(waitOptions(Duration.ofSeconds(1)))
            .moveTo(PointOption.point(489,1892))
            .release()
            .perform();

        }

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.