From 7b3a607b5edf151b8970d3fcb7e1e6502c146d1f Mon Sep 17 00:00:00 2001 From: Jordan Petridis Date: Sun, 21 Jun 2020 18:30:48 +0300 Subject: [PATCH] improve test.sh further Before we were able to call the script with ninja directly, we were trying to override some of the envvars to fix how/where cargo artifacts where stored. This is no longer an issue as ninja is making sure the proper setup will be met. This is also makes it so that Builder doesn't rebuild everything since $BUILDDIR was empty before causing rebuilds of the whole world. --- scripts/test.sh | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/scripts/test.sh b/scripts/test.sh index 9b17ee8..47747fe 100755 --- a/scripts/test.sh +++ b/scripts/test.sh @@ -6,16 +6,14 @@ set -x # $1 Passed by meson and should be the builddir export CARGO_TARGET_DIR="$1/target/" +export CARGO_HOME="$CARGO_TARGET_DIR/cargo-home" # If this is run inside a flatpak envrironment, append the export the rustc # sdk-extension binaries to the path if [ -f "/.flatpak-info" ] then export PATH="$PATH:/usr/lib/sdk/rust-stable/bin" - # This assumes its run inside a Builder terminal - export CARGO_TARGET_DIR="$BUILDDIR/target/" fi -export CARGO_HOME="$CARGO_TARGET_DIR/cargo-home" - -cargo test -- --test-threads=1 --nocapture +cargo fetch --locked +cargo test --all-features --offline -- --test-threads=1 --nocapture