Use the configuration depending on the selected database provider #13
@ -25,7 +25,7 @@ jobs:
|
|||||||
--health-timeout 5s
|
--health-timeout 5s
|
||||||
--health-retries 5
|
--health-retries 5
|
||||||
ports:
|
ports:
|
||||||
- 3306:3306
|
- 5555:3306
|
||||||
|
|
||||||
postgres:
|
postgres:
|
||||||
image: postgres:latest
|
image: postgres:latest
|
||||||
@ -39,7 +39,7 @@ jobs:
|
|||||||
--health-timeout 5s
|
--health-timeout 5s
|
||||||
--health-retries 5
|
--health-retries 5
|
||||||
ports:
|
ports:
|
||||||
- 5432:5432
|
- 6666:5432
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
@ -66,12 +66,12 @@ jobs:
|
|||||||
- name: Modify configuration for MySQL
|
- name: Modify configuration for MySQL
|
||||||
if: matrix.db-provider == 'mysql'
|
if: matrix.db-provider == 'mysql'
|
||||||
run: |
|
run: |
|
||||||
jq '.DbSettings.TypeDatabase = 0 | .DbSettings.ConnectionStringSql = "Server=127.0.0.1;Port=3306;Database=testdb;Uid=root;Pwd=root;"' Settings.json > temp.json && mv temp.json Settings.json
|
jq '.DbSettings.TypeDatabase = 0 | .DbSettings.ConnectionStringSql = "Server=127.0.0.1;Port=5555;Database=testdb;Uid=root;Pwd=root;"' Settings.json > temp.json && mv temp.json Settings.json
|
||||||
|
|
||||||
- name: Modify configuration for PostgreSQL
|
- name: Modify configuration for PostgreSQL
|
||||||
if: matrix.db-provider == 'postgresql'
|
if: matrix.db-provider == 'postgresql'
|
||||||
run: |
|
run: |
|
||||||
jq '.DbSettings.TypeDatabase = 2 | .DbSettings.ConnectionStringSql = "Host=127.0.0.1;Port=5432;Database=testdb;Username=postgres;Password=postgres"' Settings.json > temp.json && mv temp.json Settings.json
|
jq '.DbSettings.TypeDatabase = 2 | .DbSettings.ConnectionStringSql = "Host=127.0.0.1;Port=6666;Database=testdb;Username=postgres;Password=postgres"' Settings.json > temp.json && mv temp.json Settings.json
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: dotnet test --configuration Release --no-build --no-restore --verbosity normal
|
run: dotnet test --configuration Release --no-build --no-restore --verbosity normal
|
Loading…
Reference in New Issue
Block a user