ci: add a 'build-itest' job to main workflow

Adds a separate 'build-itest' job that builds the itest binaries prior
to the actual itest jobs being kicked off. With this change we'll
rebuild the itest binaries at most once, instead of at most four times.
This commit is contained in:
Jared Tobin 2026-01-23 08:21:02 +04:00
parent 5b9d357e1f
commit c64b47eec6
No known key found for this signature in database
GPG key ID: 0E4647D58F8A69E4

View file

@ -267,12 +267,37 @@ jobs:
- name: run ${{ matrix.unit_type }}
run: make ${{ matrix.unit_type }}
########################
# build itest binaries (cache warming)
########################
build-itest:
name: build itest binaries
runs-on: ubuntu-latest
steps:
- name: git checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: setup go ${{ env.GO_VERSION }}
uses: ./.github/actions/setup-go
with:
go-version: '${{ env.GO_VERSION }}'
key-prefix: itest
- name: prepare dummy static data
run: mkdir -p app/build; touch app/build/index.html
- name: build itest binaries
run: make build-itest build-itest-binary
########################
# integration tests
########################
itest:
name: integration test
runs-on: ubuntu-latest
needs: build-itest
strategy:
# Allow other tests in the matrix to continue if one fails.
fail-fast: false