Skip to content

Commit

Permalink
Switch to GitHub actions for E2E tests
Browse files Browse the repository at this point in the history
  • Loading branch information
stevesoltys committed Sep 28, 2023
1 parent 84065c4 commit feb0eaa
Showing 1 changed file with 50 additions and 50 deletions.
100 changes: 50 additions & 50 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,53 +52,53 @@ jobs:
./app/development/scripts/provision_emulator.sh "test" "system-images;android-33;default;x86_64"
echo "Generated AVD snapshot for caching."
# - name: Assemble tests
# run: ./gradlew :app:assembleAndroidTest
#
# - name: Run tests
# uses: reactivecircus/android-emulator-runner@v2
# with:
# api-level: 33
# target: default
# arch: x86_64
# force-avd-creation: false
# emulator-options: -writable-system -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
# profile: pixel_6a
# heap-size: '512M'
# ram-size: '4096M'
# disk-size: '14G'
# sdcard-path-or-size: '4096M'
# disable-animations: false
# script: |
# adb root
# sleep 5
# adb remount
#
# echo "Installing Seedvault app..."
# adb shell mkdir -p /system/priv-app/Seedvault
# adb push app/build/outputs/apk/release/app-release.apk /system/priv-app/Seedvault/Seedvault.apk
#
# echo "Installing Seedvault permissions..."
# adb push permissions_com.stevesoltys.seedvault.xml /system/etc/permissions/privapp-permissions-seedvault.xml
# adb push allowlist_com.stevesoltys.seedvault.xml /system/etc/sysconfig/allowlist-seedvault.xml
#
# echo "Setting Seedvault transport..."
# sleep 10
# adb shell bmgr transport com.stevesoltys.seedvault.transport.ConfigurableBackupTransport
#
# gradle_exit_code=0
# ./gradlew --stacktrace -Pinstrumented_test_size=large :app:connectedAndroidTest || gradle_exit_code=$?
#
# adb pull /sdcard/seedvault_test_videos
#
# if [ $gradle_exit_code -ne 0 ]; then
# echo "Gradle test failed."
# exit 1
# fi
#
# - name: Upload screenshots and videos
# if: always()
# uses: actions/upload-artifact@v3
# with:
# name: seedvault_test_videos
# path: seedvault_test_videos/**/*.mp4
- name: Assemble tests
run: ./gradlew :app:assembleAndroidTest

- name: Run tests
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 33
target: default
arch: x86_64
force-avd-creation: false
emulator-options: -writable-system -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
profile: pixel_6a
heap-size: '512M'
ram-size: '4096M'
disk-size: '14G'
sdcard-path-or-size: '4096M'
disable-animations: false
script: |
adb root
sleep 5
adb remount
echo "Installing Seedvault app..."
adb shell mkdir -p /system/priv-app/Seedvault
adb push app/build/outputs/apk/release/app-release.apk /system/priv-app/Seedvault/Seedvault.apk
echo "Installing Seedvault permissions..."
adb push permissions_com.stevesoltys.seedvault.xml /system/etc/permissions/privapp-permissions-seedvault.xml
adb push allowlist_com.stevesoltys.seedvault.xml /system/etc/sysconfig/allowlist-seedvault.xml
echo "Setting Seedvault transport..."
sleep 10
adb shell bmgr transport com.stevesoltys.seedvault.transport.ConfigurableBackupTransport
gradle_exit_code=0
./gradlew --stacktrace -Pinstrumented_test_size=large :app:connectedAndroidTest || gradle_exit_code=$?
adb pull /sdcard/seedvault_test_videos
if [ $gradle_exit_code -ne 0 ]; then
echo "Gradle test failed."
exit 1
fi
- name: Upload screenshots and videos
if: always()
uses: actions/upload-artifact@v3
with:
name: seedvault_test_videos
path: seedvault_test_videos/**/*.mp4

0 comments on commit feb0eaa

Please sign in to comment.