google / google/Accessibility-Test-Framework-for-Android
ATF skips some Compose elements when AndroidView is present in the same hierarchy
- Dominant language
- Java
- Stars
- 520
- Forks
- 154
- PR merge metrics
- No merged PRs in 30d
Description
**Description**
When using `enableAccessibilityChecks()` with Compose UI tests, ATF fails to detect
accessibility issues (e.g., TextContrastCheck) on some Compose elements when an
`AndroidView` is present in the same hierarchy.
**Steps to Reproduce**
1. Create a Compose screen with:
- A Card containing multiple Text elements with low contrast
- An AndroidView (e.g., custom Chart view)
2. Run accessibility checks
**Expected Behavior**
All low-contrast Text elements should be detected.
**Actual Behavior**
Only some Text elements are detected. Text elements that are siblings of
AndroidView are skipped.
**Environment**
- Compose: 1.8.4
- ATF: 4.1.1
- API Level: 34+
Contributor guide
Assessment
This issue has not been assessed yet.