ci(postgres): add flag to enable/disable postgres ci
This commit is contained in:
parent
420c1e7994
commit
a4304124ec
2 changed files with 6 additions and 1 deletions
6
.github/workflows/_base-server-tests.yml
vendored
6
.github/workflows/_base-server-tests.yml
vendored
|
|
@ -22,6 +22,10 @@ on:
|
|||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
enable-postgres:
|
||||
required: false
|
||||
type: boolean
|
||||
default: true
|
||||
enable-coverage:
|
||||
required: false
|
||||
type: boolean
|
||||
|
|
@ -62,7 +66,7 @@ jobs:
|
|||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
db: ${{ fromJson(inputs.enable-sqlite && '["mariadb", "postgres", "sqlite"]' || '["mariadb", "postgres"]') }}
|
||||
db: ${{ fromJson(inputs.enable-sqlite && (inputs.enable-postgres && '["mariadb", "postgres", "sqlite"]' || '["mariadb", "sqlite"]') || (inputs.enable-postgres && '["mariadb", "postgres"]' || '["mariadb"]')) }}
|
||||
index: ${{ fromJson(needs.gen-idx-integration.outputs.indices) }}
|
||||
services:
|
||||
postgres:
|
||||
|
|
|
|||
1
.github/workflows/server-tests.yml
vendored
1
.github/workflows/server-tests.yml
vendored
|
|
@ -44,6 +44,7 @@ jobs:
|
|||
name: Tests
|
||||
uses: ./.github/workflows/_base-server-tests.yml
|
||||
with:
|
||||
enable-postgres: true # This enables PostgreSQL to run tests
|
||||
enable-sqlite: false # This will test against both MariaDB and SQLite if enabled
|
||||
parallel-runs: 2
|
||||
enable-coverage: ${{ github.event_name != 'pull_request' }}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue