Skip to content

Commit 961b566

Browse files
committed
CI: run SSL tests only when building with TLS support
1 parent d32139b commit 961b566

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

.github/workflows/sqlx.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -240,6 +240,7 @@ jobs:
240240
docker exec postgres_${{ matrix.postgres }}_client_ssl bash -c "until pg_isready; do sleep 1; done"
241241
242242
- uses: actions-rs/cargo@v1
243+
if: matrix.tls != 'none'
243244
with:
244245
command: test
245246
args: >
@@ -313,7 +314,7 @@ jobs:
313314
314315
# MySQL 5.7 supports TLS but not TLSv1.3 as required by RusTLS.
315316
- uses: actions-rs/cargo@v1
316-
if: ${{ !(matrix.mysql == '5_7' && matrix.tls == 'rustls') }}
317+
if: ${{ matrix.mysql != '5_7' || matrix.tls == 'native-tls') }}
317318
with:
318319
command: test
319320
args: >
@@ -372,6 +373,7 @@ jobs:
372373
sleep 60
373374
374375
- uses: actions-rs/cargo@v1
376+
if: matrix.tls != 'none'
375377
with:
376378
command: test
377379
args: >

tests/docker.py

-6
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,6 @@ def start_database(driver, database, cwd):
3636
elif driver.startswith("postgres"):
3737
port = 5432
3838

39-
elif driver.startswith("mssql"):
40-
port = 1433
41-
4239
else:
4340
raise NotImplementedError
4441

@@ -80,8 +77,5 @@ def start_database(driver, database, cwd):
8077
elif driver.startswith("postgres"):
8178
return f"postgres://postgres{password}@localhost:{port}/{database}"
8279

83-
elif driver.startswith("mssql"):
84-
return f"mssql://sa:[email protected]:{port}/{database}"
85-
8680
else:
8781
raise NotImplementedError

0 commit comments

Comments
 (0)