Skip to content

Commit 7abd4df

Browse files
committed
[CI] Test the pinned Quaint connector before releases
1 parent 52f015a commit 7abd4df

1 file changed

Lines changed: 34 additions & 0 deletions

File tree

‎.github/workflows/compatibility.yaml‎

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,3 +97,37 @@ jobs:
9797
- run: cargo test -p postgres-protocol -p tokio-postgres --lib
9898
- run: cargo test -p tokio-postgres --test test pgbouncer_type_lookup_after_deallocate
9999
- run: cargo test -p tokio-postgres --test test database_error_retains_server_message
100+
quaint-tests:
101+
runs-on: namespace-profile-gitar
102+
steps:
103+
- uses: actions/checkout@v4
104+
- name: Read the pinned Quaint revision
105+
id: quaint
106+
run: |
107+
python3 - <<'PYTHON'
108+
import os
109+
import tomllib
110+
with open("Cargo.toml", "rb") as source:
111+
revision = tomllib.load(source)["patch"]["https://github.com/Brendonovich/quaint"]["quaint"]["rev"]
112+
with open(os.environ["GITHUB_OUTPUT"], "a") as output:
113+
output.write(f"rev={revision}\n")
114+
PYTHON
115+
- uses: actions/checkout@v4
116+
with:
117+
repository: gitarcode/quaint
118+
ref: ${{ steps.quaint.outputs.rev }}
119+
path: quaint-source
120+
- uses: dtolnay/rust-toolchain@stable
121+
with:
122+
components: clippy
123+
- uses: Swatinem/rust-cache@v2
124+
with:
125+
workspaces: quaint-source/tests/rustls -> target
126+
- run: cargo clippy --locked --manifest-path quaint-source/tests/rustls/Cargo.toml --all-targets
127+
- run: python3 quaint-source/tests/rustls/run.py
128+
- name: Verify the connector dependency tree uses rustls
129+
run: |
130+
cargo tree --locked --manifest-path quaint-source/tests/rustls/Cargo.toml -e normal,build --prefix none > /tmp/quaint-dependencies.txt
131+
if grep -E '^(native-tls|openssl|openssl-sys|postgres-native-tls) v' /tmp/quaint-dependencies.txt; then
132+
exit 1
133+
fi

0 commit comments

Comments
 (0)