Skip to content

[Bug]: [Android] Bottom sheet is completely not detectable on Appium via uiautomator2 #2589

@apoorva-quince

Description

@apoorva-quince

Version

v5

Reanimated Version

v3

Gesture Handler Version

v2

Platforms

Android

What happened?

I am rendering the bottom sheet via this library on both iOS and Android. On ios, it works fine but on Android, the appium is not able to access the bottom sheet view entirely. It behaves like its detecting only the screen and its children that are on the background of that bottom sheet.

Reproduction steps

  • <View key={modal.key} style={[styles.modalStackContainer, { zIndex }]} pointerEvents={index === activeModals.length - 1 ? "auto" : "none"} > <BottomSheet ref={(ref) => { if (ref) { modalRefs.current.set(modal.key, ref); } }} onClose={() => onCloseActions(modal.key)} onAnimate={(index) => onAnimateHandler(modal.key, index)} onChange={(index) => onOpenActions(modal.key, index)} //handleComponent={null} enablePanDownToClose={true} backdropComponent={(props) => ( <Backdrop {...props} modalKey={modal.key} isTopModal={index === activeModals.length - 1} /> )} maxDynamicContentSize={MAX_DYNAMIC_CONTENT_SIZE} snapPoints={snapPoints} enableDynamicSizing={!snapPoints?.length} accessible={false} keyboardBehavior="extend" enableOverDrag={false} > <BottomSheetProvider> <ModalView {...modalProps} onDismiss={(onModalClose) => onModalDismiss(modal.key, onModalClose) } onCloseModal={(cb) => onCloseModal(modal.key, cb)} onOpenModal={(cb) => onOpenModal(modal.key, cb)} /> </BottomSheetProvider> </BottomSheet> </View>

Run the session in Appium and try to detect the bottom sheet.
Appium settings:
{ "platformName": "Android", "appium:automationName": "UiAutomator2", "appium:deviceName": "emulator-5554", "appium:udid": "emulator-5554", "appium:appPackage": "com.lastbrand.quince", "appium:appActivity": "com.lastbrand.quince.MainActivity", "appium:autoGrantPermissions": true, "appium:autoAcceptAlerts": true, "appium:noReset": false, "appium:fullReset": false }

Reproduction sample

https://snack.expo.dev/@apoorva_verma_quince/bottom-sheet---issue-reproduction-template

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions