infinitered / ignite-bowser

Bowser is now re-integrated into Ignite CLI! Head to https://github.com/infinitered/ignite to check it out.
https://infinite.red/ignite
MIT License
615 stars 140 forks source link

Added detox e2e testing for Expo apps #378

Closed preetb123 closed 3 years ago

preetb123 commented 3 years ago

Added detox e2e tests for Expo projects. [only iOS]
Fixes https://github.com/infinitered/ignite-bowser/pull/299

I have made least amount of changes to get it working. One thing i want to mention though, the latest version of detox specifically checks for the visibility of the element and on the welcome screen welcome-screen.tsx, the Continue button at the bottom was being hidden by the LogBox popup that appears after the app opens, giving the following error

Test Failed: View “<RCTView: 0x7fa08ded38f0>” is not visible: view does not pass visibility threshold (75%)
TIP: To print view hierarchy on failed actions/matches, use loglevel verbose and above.

So i have added some marginBottom to make the button properly visible as in the below image const FOOTER: ViewStyle = { backgroundColor: "#20162D", marginBottom: 64 }

Screenshot 2020-09-29 at 1 23 55 PM

Expo application is downloaded during the generation of the project and placed in bin/

expo-detox-e2e

jamonholmgren commented 3 years ago

This is amazing! Thanks @preetb123 !!