mattermost-mobile-upstream/detox
2025-01-22 04:02:14 +05:30
..
android_emulator
e2e E2E: Mobile Drafts tests cases (#8469) 2025-01-22 04:02:14 +05:30
utils Update dependencies and upgrade to RN 0.76.5 (#8421) 2025-01-16 07:11:32 -07:00
.babelrc
.detoxrc.json Fix: Env variabled to pick up right simulator device for tests (#8367) 2024-11-29 11:48:35 +05:30
create_android_emulator.sh
inject-detox-settings.js Fix: Android build for Detox e2e (#8362) 2024-12-09 23:20:05 +05:30
package-lock.json Update dependencies and upgrade to RN 0.76.5 (#8421) 2025-01-16 07:11:32 -07:00
package.json Update dependencies and upgrade to RN 0.76.5 (#8421) 2025-01-16 07:11:32 -07:00
README.md Add android detox apk build workflow (#8405) 2025-01-16 12:26:10 +05:30
save_report.js
tsconfig.json
webhook_server.js

How to Run Detox Tests

Android

Install Dependencies

From the root directory, run the following command to install the necessary dependencies:

npm install

Inject Detox Settings

To inject the Detox settings into your project, navigate to the detox directory and run the following command:

npm run inject-detox-settings

Update minSdkVersion for react-native-image-picker

On macOS machines, update the minSdkVersion of react-native-image-picker to 23 by running the following command from the root directory. This is required for Detox to build the test apk targeting android API 31 or higher.

sed -i '' 's/minSdkVersion 21/minSdkVersion 23/' ./node_modules/react-native-image-picker/android/build.gradle

Build detox android app

From the detox folder run:

npm run e2e:android-build