Appium with Android Compose and Accessibility (EAA)

Hey everyone!

As you may know, new EU legislation (European Accessibility Act) will soon require mobile apps to comply with accessibility standards — meaning screen reader support, proper navigation, and accessibility-friendly semantics are no longer optional.Our developers recently started integrating accessibility support into our Jetpack Compose Android app, and we’ve hit a challenge that directly affects our Appium test automation (using UiAutomator2 driver).

Specifically, we’re trying to:

  • Prevent the screen reader from reading certain child elements
  • Avoid child nodes being focusable by accessibility services
  • Still keep all nodes (parent + children) visible in the UI hierarchy / page source so Appium can locate them.

But many Compose options like clearAndSetSemantics {} or invisibleToUser() completely remove child nodes from the accessibility tree — which makes them invisible to Appium as well.

Has anyone here run into the same issue?
How did you implement accessibility in a way that preserves test automation visibility?

Any tips, patterns, or workarounds would be super appreciated - Unfortunately, using Espresso driver is not feasible for us.

Thanks in advance!

Why not with automation build disable invisibility settings?

That’s one of the options we had in mind. However, it’s not our preferred way as it has some dependencies to our workflow. That’s why I’m asking if there is anyone that has some ideas.