TouchAction is not working in appium
I have followed Video Session 7 for Appium and i have used same code for TouchAction but code is not working,
Can you please take look what i am missing..
Screenshot: https://www.screencast.com/t/srFhVMku1kOh
List<MobileElement> allMobileElement=driver.findElements(By.id("com.mobeta.android.demodslv:id/text")); System.out.println("All Element are: "+allMobileElement.size()); MobileElement e1=allMobileElement.get(0); MobileElement e2=allMobileElement.get(3); System.out.println("Mobile Element e1 Text is: "+e1.getText()); System.out.println("Mobile Element e2 text is: "+e2.getText()); TouchAction action=new TouchAction(driver); action.longPress(LongPressOptions().withElement(element(e1)).withDuration(ofSeconds(5))).moveTo(element(e2)).release().perform();
Please see the screenshot for more clearity.
I have added static import now its working..
We offer online selenium and UFT/QTP training. The course is very comprehensive and covers every aspect of automation testing with UFT/QTP and selenium. All types of frameworks are covered in depth - data driven framework, hybrid framework, page object model with a live project
© 2020 Whizdom Trainings. All rights Reserved - Powered by Whizdom Trainings