Merge pull request #3740 from ByteHamster/retry-tests

Retry tests automatically
This commit is contained in:
H. Lehmann 2020-01-09 14:18:43 +01:00 committed by GitHub
commit 4bb1ee8fe6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 3 deletions

View File

@ -16,12 +16,11 @@ jobs:
- name: Build with Gradle - name: Build with Gradle
run: ./gradlew assemblePlayDebugAndroidTest run: ./gradlew assemblePlayDebugAndroidTest
- name: Android Emulator test - name: Android Emulator test
uses: ReactiveCircus/android-emulator-runner@v1.0.1 uses: ReactiveCircus/android-emulator-runner@v2.2.0
with: with:
api-level: 28 api-level: 28
headless: true
disable-animations: true disable-animations: true
script: ./gradlew connectedPlayDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.notAnnotation=de.test.antennapod.IgnoreOnCi script: zsh .github/workflows/runTests.sh
- uses: actions/upload-artifact@v1 - uses: actions/upload-artifact@v1
if: failure() if: failure()
with: with:

6
.github/workflows/runTests.sh vendored Normal file
View File

@ -0,0 +1,6 @@
runTests() {
./gradlew connectedPlayDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.notAnnotation=de.test.antennapod.IgnoreOnCi
}
# Retry tests to make them less flaky
runTests || runTests || runTests