Skip to content

Commit

Permalink
Investigate flaky tests on CI
Browse files Browse the repository at this point in the history
Set up a temporary workflow to run all flaky tests repeatedly on CI for
further investigation.
  • Loading branch information
masih committed Oct 7, 2024
1 parent 23ce86a commit bd0d2b7
Showing 1 changed file with 54 additions and 0 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/test-flaky.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Test Repeat Flaky

on:
pull_request:

jobs:
cache-test-bins:
name: Prepare go test cache
runs-on: ubuntu-latest
strategy:
matrix:
go:
- 1.22
- 1.23
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go ${{ matrix.go }}
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
cache: false
- name: Compile tests
run: go test -c -o f3-tests
- name: Cache compiled tests
uses: actions/cache/save@v4
with:
path: './f3-tests'
key: f3-tests-flaky-${{ matrix.go }}
test:
name: ${{ matrix.test }} ${{ matrix.go }}
runs-on: ubuntu-latest
needs: cache-test-bins
strategy:
fail-fast: false
matrix:
go:
- 1.22
- 1.23
test:
- TestF3LateBootstrap
- TestF3PauseResumeCatchup
- TestF3WithLookback
- TestF3FailRecover
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Restore cached built F3 test binaries
uses: actions/cache/restore@v4
with:
path: './f3-tests'
key: f3-tests-flaky-${{ matrix.go }}
- name: Repeat ${{ matrix.test }}
run: ./f3-tests -test.run=${{ matrix.test }} -test.count 50

0 comments on commit bd0d2b7

Please sign in to comment.