Skip to content

Commit e6d4359

Browse files
authored
Merge pull request #3 from SL5TaskForce/sqlx-and-clippy
Change cargo clippy to pedantic and switch sqlx to use query macros for compile-time type checks
2 parents 20d3f87 + 03e0dc0 commit e6d4359

25 files changed

Lines changed: 572 additions & 186 deletions

.cargo/config.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[env]
2+
SQLX_OFFLINE = "true"

.github/workflows/gateway.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,15 @@ jobs:
3737
--health-retries 12
3838
env:
3939
TEST_DATABASE_URL: postgres://agent_gateway_admin:agent_gateway_dev@localhost:5432/agent_gateway_test
40+
SQLX_OFFLINE: true
4041
steps:
4142
- uses: actions/checkout@v5
4243
- uses: dtolnay/rust-toolchain@stable
4344
- uses: Swatinem/rust-cache@v2
45+
- run: cargo install sqlx-cli --version 0.8.6 --locked --no-default-features --features postgres
46+
- run: SQLX_OFFLINE=false DATABASE_URL="$TEST_DATABASE_URL" cargo sqlx database setup
47+
- run: SQLX_OFFLINE=false DATABASE_URL="$TEST_DATABASE_URL" cargo sqlx prepare --check -- --all-targets --locked
48+
- run: cargo clippy --locked --all-targets
4449
- run: cargo test --locked
4550

4651
image:

.sqlx/query-2e5bfa8b38514ea1eb638c158622d5345cb1bcd943017773493f3ce555c09710.json

Lines changed: 21 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-3535f76a2186e39edf59d8e40879b7f4ac530e3a18295b3b32a9da7c7b65b7c8.json

Lines changed: 14 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-3e49d130c02ac882e0c36f80b8258fb7beba42c39921be0287db22b4a79a0b46.json

Lines changed: 14 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-47cff29e5dcfc88d719d162f656cbf02672645bc5c2565b39d8949e2a2212909.json

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-5ec9ac85b3956ecac884f312e7a8f21540c6f986aec6c6cc0f4b7ff53ffcc68a.json

Lines changed: 14 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-81ab64535042f97a4a1143873b068720752c4ab96c19a01d2ef23a716c063454.json

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-cd2c5f37e6caabc0789ca458e8bc52f23b750c3555030c5c15c40a5a13226b8f.json

Lines changed: 25 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.sqlx/query-e3b8aebb3bd68bb84e6d09cb0b214c5ba1e25a847aea0e877f2a6682a760efa6.json

Lines changed: 102 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)