Created
October 24, 2025 19:05
-
-
Save nautilytics/d68bc97b24da14f10eca5e71110acf36 to your computer and use it in GitHub Desktop.
A sample EAS workflow for running Maestro tests against an Android build
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Maestro E2e Tests - Android | |
| on: | |
| push: | |
| branches: ['main'] | |
| jobs: | |
| fingerprint: | |
| type: fingerprint | |
| environment: preview | |
| android_get_build: | |
| needs: [fingerprint] | |
| type: get-build | |
| params: | |
| fingerprint_hash: ${{ needs.fingerprint.outputs.android_fingerprint_hash }} | |
| platform: android | |
| profile: test | |
| distribution: internal | |
| channel: test | |
| android_repack: | |
| needs: [android_get_build] | |
| if: ${{ needs.android_get_build.outputs.build_id }} | |
| type: repack | |
| params: | |
| build_id: ${{ needs.android_get_build.outputs.build_id }} | |
| android_build: | |
| needs: [android_get_build] | |
| if: ${{ !needs.android_get_build.outputs.build_id }} | |
| type: build | |
| params: | |
| platform: android | |
| profile: test | |
| android_maestro: | |
| after: [android_repack, android_build] | |
| runs_on: linux-large-nested-virtualization | |
| image: auto | |
| env: | |
| MAESTRO_APP_ID: ${{ needs.android_repack.outputs.app_identifier || needs.android_build.outputs.app_identifier }} | |
| MAESTRO_EAS_BUILD_ID: ${{ needs.android_repack.outputs.build_id || needs.android_build.outputs.build_id }} | |
| MAESTRO_TESTS_DIR: .maestro/tests | |
| steps: | |
| - uses: eas/checkout | |
| - uses: eas/download_build | |
| id: dl | |
| with: | |
| build_id: ${{ needs.android_repack.outputs.build_id || needs.android_build.outputs.build_id }} | |
| extensions: [apk] | |
| - uses: eas/start_android_emulator | |
| - uses: eas/install_maestro | |
| - name: Install app on emulator | |
| run: adb install -r "${{ steps.dl.outputs.artifact_path }}" | |
| - name: Run Maestro tests (all found in e2e/ directory) | |
| run: | | |
| mkdir -p "$MAESTRO_TESTS_DIR" | |
| maestro test e2e \ | |
| --format junit \ | |
| --output "$MAESTRO_TESTS_DIR/maestro.xml" | |
| - name: Upload screenshots to Percy | |
| if: always() | |
| run: | | |
| npx @percy/cli upload \ | |
| --strip-extensions "$MAESTRO_TESTS_DIR" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment