Testing A Recyclerview: Recyclerviewactions Isn't Scrolling Far Enough
I want my espresso test to scroll a RecyclerView down until it's sees a certain view and clicks it. Therefore I am using RecyclerViewActions: onView(withId(R.id.recycler)).perform(
Solution 1:
I've found the reason why the view action wasn't successul:
The app has a collapsible toolbar which was expanded before I started the scroll action. When I performed the scroll action the toolbar collapsed first and then the recycler view scrolled. Therefore the recycler view scrolled to little.
The solution I found is that I collapse the toolbar first with a custom AppBarViewAction. The solution is found here
Post a Comment for "Testing A Recyclerview: Recyclerviewactions Isn't Scrolling Far Enough"