chore: pin crdb version for unit tests (#7260)

* chore: pin crdb version for unit tests

* use latest 23.1 version

* use latest available 23.1 version
This commit is contained in:
Livio Spring 2024-01-18 09:16:54 +01:00 committed by GitHub
parent af4e0484d0
commit 8470649ecb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 7 additions and 3 deletions

View File

@ -48,6 +48,7 @@ jobs:
go_version: "1.21"
core_cache_key: ${{ needs.core.outputs.cache_key }}
core_cache_path: ${{ needs.core.outputs.cache_path }}
crdb_version: "23.1.13"
core-integration-test:
needs: core

View File

@ -12,6 +12,9 @@ on:
core_cache_path:
required: true
type: string
crdb_version:
required: false
type: string
jobs:
test:
@ -51,7 +54,7 @@ jobs:
-
name: test
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
run: make core_unit_test
run: export ZITADEL_CRDB_VERSION="${{ inputs.crdb_version }}" && make core_unit_test
-
name: publish coverage
uses: codecov/codecov-action@v3.1.4

View File

@ -27,7 +27,7 @@ var (
)
func TestMain(m *testing.M) {
ts, err := testserver.NewTestServer()
ts, err := testserver.NewTestServer(testserver.CustomVersionOpt(os.Getenv("ZITADEL_CRDB_VERSION")))
if err != nil {
logging.WithFields("error", err).Fatal("unable to start db")
}

View File

@ -20,7 +20,7 @@ var (
)
func TestMain(m *testing.M) {
ts, err := testserver.NewTestServer()
ts, err := testserver.NewTestServer(testserver.CustomVersionOpt(os.Getenv("ZITADEL_CRDB_VERSION")))
if err != nil {
logging.WithFields("error", err).Fatal("unable to start db")
}