ClassCastException while using TouchActions Flick
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.3k
- Forks
- 752
- Avg merge
- 6d 21h
- Merged PRs (30d)
- 8
Description
Hi @mykola-mokhnach , @jlipps , @rossrowe
I am trying to use flick method of touch actions on android app but every-time i use it i get below mentioned error.
java.lang.ClassCastException: io.appium.java_client.android.AndroidDriver cannot be cast to org.openqa.selenium.interactions.HasTouchScreen
at org.openqa.selenium.interactions.touch.TouchActions.(TouchActions.java:38)
Here is the method:-
TouchActions action = new TouchActions(driver);
action.flick(100, 100);
action.perform();
My requirement is to fast scroll like flick to the bottom of the page. i know other scroll option but they are really slow. so thought of using flick but unfortunately its not working.
I am using:-
Appium version:- 1.13.0
Android Version:- 8.0
AutomationName:- UiAutomator2
Please reply at the earliest.
Regards
Syed Zubair
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the TouchActions constructor at org.openqa.selenium.interactions.touch.TouchActions.java:38 and the AndroidDriver used in the provided flick snippet. Reproduce the ClassCastException with Appium 1.13.0, Android 8.0, and UiAutomator2, then determine whether the Java client can support this interaction; done means the documented flick flow no longer fails with the cast error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- mobile, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100