From d76bb053d0015e0c3adfaf2e1aa3f31dedae70ae Mon Sep 17 00:00:00 2001 From: Kilian Finger Date: Fri, 6 Dec 2024 15:01:27 +0100 Subject: [PATCH] ci: reorder jobs --- .github/workflows/review.yml | 92 ++++++++++++++++++------------------ 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/.github/workflows/review.yml b/.github/workflows/review.yml index 7a415300d..0de737aee 100644 --- a/.github/workflows/review.yml +++ b/.github/workflows/review.yml @@ -132,6 +132,52 @@ jobs: name: android-app path: ./packages/react-native-app/android/app/build/outputs/apk/release/app-release.apk + test-android: + name: Test Android + needs: [build-android] + runs-on: ubuntu-latest + defaults: + run: + working-directory: ./packages/react-native-app + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install Maestro + run: | + curl -Ls "https://get.maestro.mobile.dev" | bash + echo "$HOME/.maestro/bin" >> "$GITHUB_PATH" + + - name: Download Android App + uses: actions/download-artifact@v4 + with: + name: android-app + path: ./packages/react-native-app/android/ + + - name: Check apk + run: | + ls -la + cd android + ls -la + + - name: Test Android + uses: reactivecircus/android-emulator-runner@v2 + with: + api-level: 29 + working-directory: ./packages/react-native-app + script: | + adb install ./android/app-release.apk + maestro test ./e2e/show-map.yml --format junit + + - name: Upload Android Report + if: always() + uses: actions/upload-artifact@v4 + with: + name: Android Report + path: | + ./packages/react-native-app/report.xml + ~/.maestro/tests/**/* + build-ios: name: Build iOS needs: [lint-eslint, lint-tsc, test, codegen, build-library] @@ -186,52 +232,6 @@ jobs: !./packages/react-native-app/ios/build/Build/Products/Release-iphonesimulator/** ./packages/react-native-app/ios/build/Build/Products/Release-iphonesimulator/MapLibreReactNativeExample.app - test-android: - name: Test Android - needs: [build-android] - runs-on: ubuntu-latest - defaults: - run: - working-directory: ./packages/react-native-app - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Install Maestro - run: | - curl -Ls "https://get.maestro.mobile.dev" | bash - echo "$HOME/.maestro/bin" >> "$GITHUB_PATH" - - - name: Download Android App - uses: actions/download-artifact@v4 - with: - name: android-app - path: ./packages/react-native-app/android/ - - - name: Check apk - run: | - ls -la - cd android - ls -la - - - name: Test Android - uses: reactivecircus/android-emulator-runner@v2 - with: - api-level: 29 - working-directory: ./packages/react-native-app - script: | - adb install ./android/app-release.apk - maestro test ./e2e/show-map.yml --format junit - - - name: Upload Android Report - if: always() - uses: actions/upload-artifact@v4 - with: - name: Android Report - path: | - ./packages/react-native-app/report.xml - ~/.maestro/tests/**/* - test-ios: name: Test iOS needs: [build-ios]