setup.sh/setup.ps1 now run install_llama_prebuilt.py --smoke-test on a freshly source-built GPU binary and retry a CPU build if it loaded on CPU only. When a GPU host's source build produces no binary, both scripts fall back to the CPU prebuilt (--cpu-fallback) as a labelled last resort instead of leaving the host without llama.cpp. setup.ps1 also guards an empty CUDA arch (no PTX-only binary, #5854). The POSIX smoke-test exit code is captured set -e safe. Adds a fake llama-server and an end-to-end spoof test that runs the real validate_server against it with no GPU.
23 lines
786 B
Bash
Executable file
23 lines
786 B
Bash
Executable file
#!/bin/sh
|
|
# Run all installer tests.
|
|
set -e
|
|
|
|
TESTS_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
|
|
echo "=== Bash tests ==="
|
|
sh "$TESTS_DIR/sh/test_get_torch_index_url.sh"
|
|
sh "$TESTS_DIR/sh/test_mac_intel_compat.sh"
|
|
sh "$TESTS_DIR/sh/test_torch_constraint.sh"
|
|
sh "$TESTS_DIR/sh/test_nvcc_meets_llama_minimum.sh"
|
|
sh "$TESTS_DIR/sh/test_llama_gpu_smoke.sh"
|
|
|
|
echo ""
|
|
echo "=== Python tests ==="
|
|
python -m pytest "$TESTS_DIR/python/test_install_python_stack.py" -v
|
|
python -m pytest "$TESTS_DIR/python/test_cross_platform_parity.py" -v
|
|
python -m pytest "$TESTS_DIR/python/test_no_torch_filtering.py" -v
|
|
python -m pytest "$TESTS_DIR/python/test_studio_import_no_torch.py" -v
|
|
python -m pytest "$TESTS_DIR/python/test_tokenizers_and_torch_constraint.py" -v -k "not e2e"
|
|
|
|
echo ""
|
|
echo "All tests passed."
|