AndroidStaggeredGrid
AndroidStaggeredGrid copied to clipboard
UiAutomator doesn't operate properly
Trying to run UiAutomator on a StaggeredGridView won't work properly after rotations. The behavior is not consistent as sometimes one rotation is enough to break UiAutomator and sometimes you need more but ultimately it will stop working. This seems to be related to the Accessibility Service not being able to properly identify the views.
More details there: https://github.com/novoda/Spikes/tree/master/StaggeredWithAccessibility
This is when you first start the app: This is after a few rotations: As you can see View 4 has gone missing.
Note this is using https://github.com/novoda/Spikes/tree/master/StaggeredWithAccessibility & if you replace AndroidStaggeredGrid with ListView or GridView the issue is not there.
With this simple layout it does not happen that often, but when the complexity of the layout is increased it happens more often. (the complexity of your list items).