Skip to content

Commit

Permalink
Update retry logic for flaky tests
Browse files Browse the repository at this point in the history
  • Loading branch information
paulb777 committed May 20, 2024
1 parent 61c10bc commit ea53aae
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 9 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/crashlytics.yml
Original file line number Diff line number Diff line change
Expand Up @@ -198,5 +198,10 @@ jobs:
- uses: ruby/setup-ruby@v1
- name: Setup Bundler
run: scripts/setup_bundler.sh
- name: PodLibLint Auth Cron
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseCrashlytics.podspec --platforms=${{ matrix.target }} ${{ matrix.flags }}
- uses: nick-fields/retry@v3
with:
timeout_minutes: 120
max_attempts: 3
retry_on: error
retry_wait_seconds: 120
command: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseCrashlytics.podspec --platforms=${{ matrix.target }} ${{ matrix.flags }}
28 changes: 21 additions & 7 deletions .github/workflows/sessions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,13 @@ jobs:
run: scripts/setup_bundler.sh
- name: Xcode
run: sudo xcode-select -s /Applications/${{ matrix.xcode }}.app/Contents/Developer
- name: Build and test
run: |
scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseSessions.podspec \
- uses: nick-fields/retry@v3
with:
timeout_minutes: 120
max_attempts: 3
retry_on: error
retry_wait_seconds: 120
command: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseSessions.podspec \
--platforms=${{ matrix.target }} ${{ matrix.tests }}

spm:
Expand Down Expand Up @@ -71,8 +75,13 @@ jobs:
run: sudo xcode-select -s /Applications/${{ matrix.xcode }}.app/Contents/Developer
- name: Initialize xcodebuild
run: scripts/setup_spm_tests.sh
- name: Unit Tests
run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseSessionsUnit ${{ matrix.target }} spm
- uses: nick-fields/retry@v3
with:
timeout_minutes: 120
max_attempts: 3
retry_on: error
retry_wait_seconds: 120
command: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseSessionsUnit ${{ matrix.target }} spm

catalyst:
# Don't run on private repo unless it is a PR.
Expand All @@ -87,5 +96,10 @@ jobs:
- uses: ruby/setup-ruby@v1
- name: Setup Bundler
run: scripts/setup_bundler.sh
- name: Setup project and Build for Catalyst
run: scripts/test_catalyst.sh FirebaseSessions test FirebaseSessions-Unit-unit
- uses: nick-fields/retry@v3
with:
timeout_minutes: 120
max_attempts: 3
retry_on: error
retry_wait_seconds: 120
command: scripts/test_catalyst.sh FirebaseSessions test FirebaseSessions-Unit-unit

0 comments on commit ea53aae

Please sign in to comment.