@@ -34,19 +34,19 @@ jobs:
3434 save-if : ${{ false }}
3535 - name : Run clippy for core with all features
3636 run : |
37- cargo clippy --manifest-path sqlx-core/Cargo.toml \
37+ cargo clippy --locked -- manifest-path sqlx-core/Cargo.toml \
3838 --no-default-features \
3939 --features offline,all-databases,all-types,migrate,${{ matrix.tls }} \
4040 -- -D warnings
4141 - name : Run clippy for root with all features
4242 run : |
43- cargo clippy \
43+ cargo clippy --locked \
4444 --no-default-features \
4545 --features offline,all-databases,all-types,migrate,${{ matrix.tls }},macros \
4646 -- -D warnings
4747 - name : Run clippy for all targets
4848 run : |
49- cargo clippy \
49+ cargo clippy --locked \
5050 --no-default-features \
5151 --all-targets \
5252 --features offline,all-databases,all-types,migrate,${{ matrix.tls }} \
6666 save-if : ${{ false }}
6767 - run : sudo apt-get update && sudo apt-get install -y libodbc2 unixodbc-dev
6868 if : ${{ matrix.os == 'ubuntu-latest' }}
69- - run : cargo test
69+ - run : cargo test --locked
7070 --manifest-path sqlx-core/Cargo.toml
7171 --features offline,all-databases,all-types,rustls
7272
9696 with :
9797 prefix-key : v1-sqlx
9898 save-if : ${{ github.ref == 'refs/heads/main' }}
99- - run : cargo build
99+ - run : cargo build --locked
100100 --manifest-path sqlx-cli/Cargo.toml
101101 --bin cargo-sqlx
102102 ${{ matrix.args }}
@@ -123,11 +123,11 @@ jobs:
123123 save-if : ${{ github.ref == 'refs/heads/main' && matrix.tls == 'native-tls' }}
124124 - name : Run clippy for sqlite
125125 run : |
126- cargo clippy \
126+ cargo clippy --locked \
127127 --no-default-features \
128128 --features sqlite,all-types,${{ matrix.tls }},macros,migrate \
129129 -- -D warnings
130- - run : cargo test
130+ - run : cargo test --locked
131131 --no-default-features
132132 --features any,macros,migrate,sqlite,all-types,${{ matrix.tls }}
133133 env :
@@ -153,15 +153,15 @@ jobs:
153153 save-if : ${{ github.ref == 'refs/heads/main' && matrix.postgres == '14' }}
154154
155155 - run : |
156- cargo build --features postgres,all-types,${{ matrix.tls }}
156+ cargo build --locked -- features postgres,all-types,${{ matrix.tls }}
157157 env:
158158 # FIXME: needed to disable `ltree` tests in Postgres 9.6
159159 # but `PgLTree` should just fall back to text format
160160 RUSTFLAGS: --cfg postgres_${{ matrix.postgres }}
161161
162162 - name : Run clippy for postgres
163163 run : |
164- cargo clippy \
164+ cargo clippy --locked \
165165 --no-default-features \
166166 --features postgres,all-types,${{ matrix.tls }},macros,migrate \
167167 -- -D warnings
@@ -173,15 +173,15 @@ jobs:
173173 docker exec postgres_${{ matrix.postgres }} bash -c "until pg_isready; do sleep 1; done"
174174
175175 - run : |
176- cargo test --no-default-features --features any,postgres,macros,all-types,${{ matrix.tls }}
176+ cargo test --locked -- no-default-features --features any,postgres,macros,all-types,${{ matrix.tls }}
177177 env:
178178 DATABASE_URL: postgres://postgres:password@localhost:5432/sqlx
179179 # FIXME: needed to disable `ltree` tests in Postgres 9.6
180180 # but `PgLTree` should just fall back to text format
181181 RUSTFLAGS: --cfg postgres_${{ matrix.postgres }}
182182
183183 - run : |
184- cargo test --no-default-features --features any,postgres,macros,migrate,all-types,${{ matrix.tls }}
184+ cargo test --locked -- no-default-features --features any,postgres,macros,migrate,all-types,${{ matrix.tls }}
185185 env:
186186 DATABASE_URL: postgres://postgres:password@localhost:5432/sqlx?sslmode=verify-ca&sslrootcert=./tests/certs/ca.crt
187187 # FIXME: needed to disable `ltree` tests in Postgres 9.6
@@ -201,7 +201,7 @@ jobs:
201201 save-if : ${{ false }}
202202 - run : docker compose up --wait postgres_16
203203 working-directory : tests
204- - run : cargo test --no-default-features --features any,postgres,macros,all-types,rustls
204+ - run : cargo test --locked -- no-default-features --features any,postgres,macros,all-types,rustls
205205 env :
206206 DATABASE_URL : postgres://postgres@localhost:5432/sqlx?sslmode=verify-ca&sslrootcert=./tests/certs/ca.crt&sslcert=./tests/certs/client.crt&sslkey=./tests/keys/client.key
207207
@@ -223,11 +223,11 @@ jobs:
223223 save-if : ${{ github.ref == 'refs/heads/main' && matrix.mysql == '8' }}
224224
225225 - run : |
226- cargo build --features mysql,all-types,${{ matrix.tls }}
226+ cargo build --locked -- features mysql,all-types,${{ matrix.tls }}
227227
228228 - name : Run clippy for mysql
229229 run : |
230- cargo clippy \
230+ cargo clippy --locked \
231231 --no-default-features \
232232 --features mysql,all-types,${{ matrix.tls }},macros,migrate \
233233 -- -D warnings
@@ -236,13 +236,13 @@ jobs:
236236 - run : sleep 60
237237
238238 - run : |
239- cargo test --no-default-features --features any,mysql,macros,migrate,all-types,${{ matrix.tls }}
239+ cargo test --locked -- no-default-features --features any,mysql,macros,migrate,all-types,${{ matrix.tls }}
240240 env:
241241 DATABASE_URL: mysql://root:password@localhost:3306/sqlx?ssl-mode=disabled
242242
243243 # MySQL 5.7 supports TLS but not TLSv1.3 as required by RusTLS.
244244 - run : |
245- cargo test --no-default-features --features any,mysql,macros,migrate,all-types,${{ matrix.tls }}
245+ cargo test --locked -- no-default-features --features any,mysql,macros,migrate,all-types,${{ matrix.tls }}
246246 if: ${{ !(matrix.mysql == '5_7' && matrix.tls == 'rustls') }}
247247 env:
248248 DATABASE_URL: mysql://root:password@localhost:3306/sqlx
@@ -265,11 +265,11 @@ jobs:
265265 save-if : ${{ github.ref == 'refs/heads/main' && matrix.mariadb == '10_6' }}
266266
267267 - run : |
268- cargo build --features mysql,${{ matrix.tls }}
268+ cargo build --locked -- features mysql,${{ matrix.tls }}
269269
270270 - name : Run clippy for mariadb
271271 run : |
272- cargo clippy \
272+ cargo clippy --locked \
273273 --no-default-features \
274274 --features mysql,${{ matrix.tls }},macros,migrate \
275275 -- -D warnings
@@ -278,7 +278,7 @@ jobs:
278278 - run : sleep 30
279279
280280 - run : |
281- cargo test --no-default-features --features any,mysql,macros,migrate,${{ matrix.tls }}
281+ cargo test --locked -- no-default-features --features any,mysql,macros,migrate,${{ matrix.tls }}
282282 env:
283283 DATABASE_URL: mysql://root:password@localhost:3306/sqlx
284284
@@ -300,11 +300,11 @@ jobs:
300300 save-if : ${{ github.ref == 'refs/heads/main' && matrix.mssql == '2022' }}
301301
302302 - run : |
303- cargo build --features mssql,all-types,${{ matrix.tls }}
303+ cargo build --locked -- features mssql,all-types,${{ matrix.tls }}
304304
305305 - name : Run clippy for mssql
306306 run : |
307- cargo clippy \
307+ cargo clippy --locked \
308308 --no-default-features \
309309 --features mssql,all-types,${{ matrix.tls }},macros,migrate \
310310 -- -D warnings
@@ -313,7 +313,7 @@ jobs:
313313 - run : sleep 80 # MSSQL takes a "bit" to startup
314314
315315 - run : |
316- cargo test --no-default-features --features any,mssql,macros,migrate,all-types,${{ matrix.tls }}
316+ cargo test --locked -- no-default-features --features any,mssql,macros,migrate,all-types,${{ matrix.tls }}
317317 env:
318318 DATABASE_URL: mssql://sa:Password123!@localhost/sqlx
319319
@@ -344,10 +344,10 @@ jobs:
344344 odbcinst -q -s || true
345345 echo "select 1;" | isql -v SQLX_PG_5432 || true
346346 - name : Run ODBC tests (PostgreSQL DSN)
347- run : cargo test --no-default-features --features any,odbc,macros,all-types,rustls
347+ run : cargo test --locked -- no-default-features --features any,odbc,macros,all-types,rustls
348348 env :
349349 DATABASE_URL : DSN=SQLX_PG_5432;UID=postgres;PWD=password
350350 - name : Run ODBC tests (SQLite driver)
351- run : cargo test --no-default-features --features any,odbc,macros,all-types,rustls
351+ run : cargo test --locked -- no-default-features --features any,odbc,macros,all-types,rustls
352352 env :
353353 DATABASE_URL : Driver={SQLite3};Database=./tests/odbc/sqlite.db
0 commit comments