Skip to content

Commit 8e655be

Browse files
committed
test: add lint checks for sqlx
1 parent c685a72 commit 8e655be

File tree

2 files changed

+25
-8
lines changed

2 files changed

+25
-8
lines changed

tasks/test.sh

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,26 +23,34 @@ echo ""
2323
echo "Building EQL..."
2424
mise run build --force
2525

26+
# Run lints on sqlx tests
27+
echo ""
28+
echo "=============================================="
29+
echo "1/3: Running linting checks on SQLx Rust tests"
30+
echo "=============================================="
31+
mise run test:lint
32+
2633
# Run legacy SQL tests
2734
echo ""
28-
echo "=========================================="
29-
echo "1/2: Running Legacy SQL Tests"
30-
echo "=========================================="
35+
echo "=============================================="
36+
echo "2/3: Running Legacy SQL Tests"
37+
echo "=============================================="
3138
mise run test:legacy --postgres ${POSTGRES_VERSION}
3239

3340
# Run SQLx Rust tests
3441
echo ""
35-
echo "=========================================="
36-
echo "2/2: Running SQLx Rust Tests"
37-
echo "=========================================="
42+
echo "=============================================="
43+
echo "3/3: Running SQLx Rust Tests"
44+
echo "=============================================="
3845
mise run test:sqlx
3946

4047
echo ""
41-
echo "=========================================="
48+
echo "=============================================="
4249
echo "✅ ALL TESTS PASSED"
43-
echo "=========================================="
50+
echo "=============================================="
4451
echo ""
4552
echo "Summary:"
53+
echo " ✓ SQLx Rust lint checks"
4654
echo " ✓ Legacy SQL tests"
4755
echo " ✓ SQLx Rust tests"
4856
echo ""

tasks/test/lint.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/usr/bin/env bash
2+
#MISE description="Run lint tests"
3+
4+
set -euo pipefail
5+
6+
(
7+
cd tests/sqlx/
8+
cargo fmt --check -- --files-with-diff
9+
)

0 commit comments

Comments
 (0)