Skip to content

Commit

Permalink
Retry up to three times when tests fail
Browse files Browse the repository at this point in the history
  • Loading branch information
stevesoltys committed Oct 11, 2023
1 parent 04832d9 commit e250214
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 15 deletions.
31 changes: 17 additions & 14 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,21 +65,24 @@ jobs:
run: ./gradlew :app:assembleAndroidTest

- name: Run tests
uses: reactivecircus/android-emulator-runner@v2
uses: Wandalen/[email protected]
with:
api-level: ${{ matrix.android_target }}
target: ${{ matrix.emulator_type }}
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'
cores: 3
disable-animations: false
script: ./.github/scripts/run_tests.sh
attempt_limit: 3
action: reactivecircus/android-emulator-runner@v2
with: |
api-level: ${{ matrix.android_target }}
target: ${{ matrix.emulator_type }}
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'
cores: 2
disable-animations: true
script: ./.github/scripts/run_tests.sh
- name: Upload test results
if: always()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,6 @@ abstract class UiDeviceScreen<T> {

private fun device() = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation())
.also {
Configurator.getInstance().waitForSelectorTimeout = 60000
Configurator.getInstance().waitForSelectorTimeout = 180000
}
}

0 comments on commit e250214

Please sign in to comment.