Skip to content

Commit

Permalink
ci test 1
Browse files Browse the repository at this point in the history
  • Loading branch information
deepanchal committed Aug 23, 2023
1 parent 864e9fa commit f37db5a
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 27 deletions.
55 changes: 28 additions & 27 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,20 @@ jobs:
- name: Installing Maestro 📥
run: curl -Ls "https://get.maestro.mobile.dev" | bash # will use `MAESTRO_VERSION` from env

- name: Validate Gradle Wrapper 📝
uses: gradle/wrapper-validation-action@v1

- name: Copy CI gradle.properties 📋
run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties

- name: Set up JDK 17 ⚙️
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: 17

- name: Setup Gradle ⚙️
uses: gradle/gradle-build-action@v2
# - name: Validate Gradle Wrapper 📝
# uses: gradle/wrapper-validation-action@v1
#
# - name: Copy CI gradle.properties 📋
# run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
#
# - name: Set up JDK 17 ⚙️
# uses: actions/setup-java@v3
# with:
# distribution: 'zulu'
# java-version: 17
#
# - name: Setup Gradle ⚙️
# uses: gradle/gradle-build-action@v2

- name: Setup environment ⚙️
env:
Expand All @@ -51,23 +51,24 @@ jobs:
echo 'DEBUG_EMAIL_ADDRESS="${{ secrets.TEST_APP_EMAIL_PROD }}"' >> ${{ env.ENV_VAR_FILE_NAME }}
echo 'DEBUG_ACCOUNT_PASSWORD="${{ secrets.TEST_APP_PASSWORD_PROD }}"' >> ${{ env.ENV_VAR_FILE_NAME }}
- name: Build apk for emulator 🏗️
run: |
./gradlew assembleDebug --no-daemon -PreactNativeArchitectures=${{ env.ANDROID_ARCH }}
echo "Print path to *.apk file"
find . -type f -name "*.apk"
# - name: Build apk for emulator 🏗️
# run: |
# ./gradlew assembleDebug --no-daemon -PreactNativeArchitectures=${{ env.ANDROID_ARCH }}
#
# echo "Print path to *.apk file"
# find . -type f -name "*.apk"

- name: Upload build outputs (APKs) 📤
uses: actions/upload-artifact@v3
with:
name: apks
path: '**/build/outputs/apk/**/*.apk'
# - name: Upload build outputs (APKs) 📤
# uses: actions/upload-artifact@v3
# with:
# name: apks
# path: '**/build/outputs/apk/**/*.apk'

- name: Run E2e tests 🧪
uses: reactivecircus/android-emulator-runner@v2
env:
APK_PATH: ./app/build/outputs/apk/demo/debug/app-demo-debug.apk
# APK_PATH: ./app/build/outputs/apk/demo/debug/app-demo-debug.apk
APK_PATH: ./app/app-demo-debug.apk
MAESTRO_DRIVER_STARTUP_TIMEOUT: 60000
MAESTRO_APP_ID: com.crisiscleanup.demo.debug
MAESTRO_APP_EMAIL: ${{ secrets.TEST_APP_EMAIL_PROD }}
Expand All @@ -86,4 +87,4 @@ jobs:
with:
name: e2e_android_report
path: |
report.xml
/Users/runner/.maestro/tests
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -288,3 +288,5 @@ core/database/schemas/com.crisiscleanup.core.database.TestCrisisCleanupDatabase
# Direnv
!.envrc
.envrc.local

!app/*.apk
Binary file added app/app-demo-debug.apk
Binary file not shown.

0 comments on commit f37db5a

Please sign in to comment.