-
Notifications
You must be signed in to change notification settings - Fork 71
/
ci-check.sh
executable file
·31 lines (23 loc) · 960 Bytes
/
ci-check.sh
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
#!/bin/sh
# We try to support some older versions of rustc. However, the support is
# tiered a bit. Our dev-dependencies do *not* guarantee that old minimal
# version. So we don't do tests on the older ones. Also, the
# signal-hook-registry supports older rustc than we signal-hook.
set -ex
rm -f Cargo.lock
cargo build --all --exclude signal-hook-async-std --exclude signal-hook-tokio
if [ "$RUST_VERSION" = 1.36.0 ] ; then
exit
fi
if [ "$OS" = "windows-latest" ] || [ "$RUST_VERSION" = 1.40.0 ]; then
# The async support crates rely on the iterator module
# which isn't available for windows. So exclude them
# from the build.
# Also, some dependencies of the runtimes don't like 1.40.
EXCLUDE_FROM_BUILD="--exclude signal-hook-mio --exclude signal-hook-tokio --exclude signal-hook-async-std"
else
EXCLUDE_FROM_BUILD=""
fi
export RUSTFLAGS="-D warnings"
cargo test --all --all-features $EXCLUDE_FROM_BUILD
cargo test --all $EXCLUDE_FROM_BUILD