diff --git a/scripts/build-linux-release.sh b/scripts/build-linux-release.sh index 7b9cf17..096f422 100755 --- a/scripts/build-linux-release.sh +++ b/scripts/build-linux-release.sh @@ -50,15 +50,33 @@ export PACKAGE_RELEASE cd "$SRC" log "Linux branch: version $VERSION release $PACKAGE_RELEASE" -if [[ "${RUN_LINUX_TESTS:-1}" == "1" ]]; then - log "Linux cargo tests started" - if [[ -f Cargo.lock ]]; then - cargo test --release --locked - else - cargo test --release - fi - log "Linux cargo tests completed" -fi +TEST_MODE="${RUN_LINUX_TESTS:-compile}" +case "$TEST_MODE" in + 0|off|false|no) + log "Linux cargo tests skipped" + ;; + 1|compile|check|no-run) + log "Linux cargo tests compile check started (--no-run)" + if [[ -f Cargo.lock ]]; then + cargo test --release --locked --no-run + else + cargo test --release --no-run + fi + log "Linux cargo tests compile check completed" + ;; + full|run) + log "Linux full cargo tests started" + if [[ -f Cargo.lock ]]; then + cargo test --release --locked + else + cargo test --release + fi + log "Linux full cargo tests completed" + ;; + *) + fatal "invalid RUN_LINUX_TESTS=$TEST_MODE (use: 0, 1/compile, or full)" + ;; +esac log "Linux cargo build started" if [[ -f Cargo.lock ]]; then diff --git a/tests/check-rustproxy-source.sh b/tests/check-rustproxy-source.sh index 58ba015..5de5eb9 100755 --- a/tests/check-rustproxy-source.sh +++ b/tests/check-rustproxy-source.sh @@ -14,8 +14,7 @@ for f in \ done grep -q '^name = "rust-proxy"' "$SRC/Cargo.toml" -grep -q '^version = "0.26.6"' "$SRC/Cargo.toml" grep -q '^ExecStart=/usr/bin/rust-proxy serve' "$SRC/debian/rustproxy.service" grep -q '^RUST_PROXY_DATA_DIR=/var/lib/rustproxy' "$SRC/debian/rustproxy.environment" -echo 'RustProxy 0.26.6 packaging layout: OK' +echo 'RustProxy packaging layout: OK'