CI: Use xvfb-run for C++ tests that require display (Qt GUI tests)

This commit is contained in:
forbes
2026-01-27 17:14:55 -06:00
parent e554244cc8
commit 8a8ee08c68
2 changed files with 37649 additions and 4 deletions

View File

@@ -69,18 +69,19 @@ jobs:
- name: Run C++ unit tests
shell: bash
run: |
pixi run ctest --test-dir build/release --output-on-failure --timeout 120 --verbose 2>&1 && exit 0
# Use xvfb for tests that require a display (Qt GUI tests)
pixi run xvfb-run -a ctest --test-dir build/release --output-on-failure --timeout 120 2>&1 && exit 0
EXITCODE=$?
echo ""
echo "=========================================="
echo "TESTS FAILED - Exit code: $EXITCODE"
echo "=========================================="
echo ""
echo "=== ctest output (last 200 lines) ==="
tail -200 build/release/Testing/Temporary/LastTest.log 2>/dev/null || echo "No LastTest.log found"
echo ""
echo "=== Failed tests ==="
cat build/release/Testing/Temporary/LastTestsFailed.log 2>/dev/null || echo "No LastTestsFailed.log found"
echo ""
echo "=== Last test log (last 100 lines) ==="
tail -100 build/release/Testing/Temporary/LastTest.log 2>/dev/null || echo "No LastTest.log found"
exit $EXITCODE
- name: Install