Files
qbz/scripts/cargo-test.sh
T
Afonso Jorge Ramos 54da577d56 ci(test-crates): align workflow with release CI conventions
Match naming, permissions, concurrency, mold linker, and cache save-if
policy (write only from pre-release) used by the Slint release jobs.
2026-07-10 01:02:37 +02:00

29 lines
866 B
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env bash
# Run the shipping-stack unit/doc tests (crates workspace).
#
# Same command CI uses (.github/workflows/test-crates.yml). Excludes the Slint
# UI compile graph (qbz-ui + dependents) so a laptop / Actions runner never hits
# the 20–30 GB UI memory wall. qbz-ui has no #[test]s; the binary crate's tests
# need a full Slint link and stay out of the default suite.
#
# Usage:
# ./scripts/cargo-test.sh
# ./scripts/cargo-test.sh -- --lib # skip doctests
# CARGO_BUILD_JOBS=1 ./scripts/cargo-test.sh
set -euo pipefail
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
cd "$ROOT"
export CARGO_BUILD_JOBS="${CARGO_BUILD_JOBS:-2}"
exec cargo test \
--manifest-path crates/Cargo.toml \
--workspace \
--exclude qbz \
--exclude qbz-ui \
--exclude qbz-dac-wizard \
--exclude qbz-slint-common \
--no-fail-fast \
"$@"