fix(ci): run Qt tests headless in Docker/CI

Use QCoreApplication for the race test, set QT_QPA_PLATFORM=offscreen
and QT_MEDIA_BACKEND=ffmpeg for playback tests, and export the same vars
in CI before ctest to avoid subprocess aborts without a display.
This commit is contained in:
Sebastian Palencsar
2026-06-21 08:56:03 +02:00
parent f4b3109c32
commit 722f417c53
4 changed files with 28 additions and 5 deletions

View File

@@ -35,6 +35,8 @@ jobs:
qt6-multimedia-ffmpeg
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build -j"$(nproc)"
export QT_QPA_PLATFORM=offscreen
export QT_MEDIA_BACKEND=ffmpeg
ctest --test-dir build --output-on-failure
"$(/usr/lib/qt6/bin/qtpaths6 --query QT_INSTALL_BINS)/qmllint" src/qml/Main.qml src/qml/components/*.qml src/qml/theme/BearTheme.qml
'