-
Notifications
You must be signed in to change notification settings - Fork 1
39 lines (33 loc) · 1.14 KB
/
test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: test
on:
push:
jobs:
cargo-test:
name: run cargo test
runs-on: ubuntu-latest
env:
CARGO_NET_GIT_FETCH_WITH_CLI: "true"
RUSTFLAGS: "-D warnings" # fail on warnings
steps:
- uses: actions/checkout@v4
- name: install tools
run: |
rustup show
- uses: Swatinem/rust-cache@v2
with:
shared-key: "build" # share the cache across jobs
save-if: false
- name: run tests
run: cargo test --release --all-targets --all-features
- name: check openssl is not a dependency of ndc-sdk-core
run: |
output=$(cargo tree -i openssl --no-dedupe --no-default-features -e no-dev)
echo "$output"
if echo "$output" | grep -q ndc-sdk-core; then
echo "openssl was found as a dependency of ndc-sdk-core"
echo "This should be fixed. openssl dependencies make it hard to make binaries with minimal dynamically linked dependencies such as connector CLI plugins"
exit 1
else
echo "openssl does not appear to be a dependency of ndc-sdk-core 🎉"
exit 0
fi