2017-04-29 13:17:22 +02:00
|
|
|
#!/bin/sh
|
2017-10-22 06:07:16 +02:00
|
|
|
# Test all Rust crates
|
2017-04-29 13:17:22 +02:00
|
|
|
|
2017-10-22 06:07:16 +02:00
|
|
|
crates="protover tor_util smartlist tor_allocate"
|
2017-04-29 13:17:22 +02:00
|
|
|
|
|
|
|
exitcode=0
|
|
|
|
|
2017-10-27 18:54:52 +02:00
|
|
|
set -e
|
|
|
|
|
2017-04-29 13:17:22 +02:00
|
|
|
for crate in $crates; do
|
|
|
|
cd "${abs_top_srcdir:-.}/src/rust/${crate}"
|
2017-10-27 18:54:52 +02:00
|
|
|
CARGO_TARGET_DIR="${abs_top_builddir:-../../..}/src/rust/target" CARGO_HOME="${abs_top_builddir:-../../..}/src/rust" "${CARGO:-cargo}" test ${CARGO_ONLINE-"--frozen"} || exitcode=1
|
2017-10-22 06:07:16 +02:00
|
|
|
cd -
|
2017-04-29 13:17:22 +02:00
|
|
|
done
|
|
|
|
|
|
|
|
exit $exitcode
|