mirror of
https://github.com/Z3Prover/z3
synced 2025-04-14 21:08:46 +00:00
Previously the `test-z3` executable was run without arguments which appears to run no tests. To fix this the `/a` argument is passed which will run all tests that don't require arguments. This was noticed in #1159 when @KarenHuang2016 reported a failing test.
27 lines
572 B
Bash
Executable file
27 lines
572 B
Bash
Executable file
#!/bin/bash
|
|
|
|
SCRIPT_DIR="$( cd ${BASH_SOURCE[0]%/*} ; echo $PWD )"
|
|
. ${SCRIPT_DIR}/run_quiet.sh
|
|
|
|
set -x
|
|
set -e
|
|
set -o pipefail
|
|
|
|
: ${Z3_BUILD_DIR?"Z3_BUILD_DIR must be specified"}
|
|
: ${RUN_UNIT_TESTS?"RUN_UNIT_TESTS must be specified"}
|
|
|
|
if [ "X${RUN_UNIT_TESTS}" != "X1" ]; then
|
|
echo "Skipping unit tests"
|
|
exit 0
|
|
fi
|
|
|
|
# Set CMake generator args
|
|
source ${SCRIPT_DIR}/set_generator_args.sh
|
|
|
|
cd "${Z3_BUILD_DIR}"
|
|
|
|
# Build and run internal tests
|
|
cmake --build $(pwd) --target test-z3 "${GENERATOR_ARGS[@]}"
|
|
# Run all tests that don't require arguments
|
|
run_quiet ./test-z3 /a
|