Skip to content

Commit

Permalink
Prospective CI fix: Run the Qt widget tests with --test-threads=1
Browse files Browse the repository at this point in the history
Otherwise Qt segfault as it's not thread safe to have widgets in
different threads
  • Loading branch information
ogoffart committed Apr 2, 2024
1 parent 3fb6bd7 commit 2c53248
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,14 @@ jobs:
if [ ! -f ./Cargo.lock ]; then
cargo update -p clap --precise 4.4.18
fi
- name: Run tests
run: DYLD_FRAMEWORK_PATH=$Qt5_DIR/lib cargo test --verbose --all-features --workspace ${{ matrix.extra_args }} --exclude slint-node --exclude pyslint --exclude test-driver-node --exclude slint-node --exclude test-driver-nodejs --exclude test-driver-cpp --exclude mcu-board-support --exclude printerdemo_mcu --exclude uefi-demo --exclude slint-cpp
- name: Run tests (not qt)
run: DYLD_FRAMEWORK_PATH=$Qt5_DIR/lib cargo test --verbose --all-features --workspace ${{ matrix.extra_args }} --exclude slint-node --exclude pyslint --exclude test-driver-node --exclude slint-node --exclude test-driver-nodejs --exclude test-driver-cpp --exclude mcu-board-support --exclude printerdemo_mcu --exclude uefi-demo --exclude slint-cpp -- --skip=_qt::t
env:
SLINT_CREATE_SCREENSHOTS: 1
shell: bash
- name: Run tests (qt)
run: DYLD_FRAMEWORK_PATH=$Qt5_DIR/lib cargo test --verbose --all-features --workspace ${{ matrix.extra_args }} --exclude slint-node --exclude pyslint --exclude test-driver-node --exclude slint-node --exclude test-driver-nodejs --exclude test-driver-cpp --exclude mcu-board-support --exclude printerdemo_mcu --exclude uefi-demo --exclude slint-cpp --bin test-driver-rust -- _qt --test-threads=1
shell: bash
- name: Archive screenshots after failed tests
if: ${{ failure() }}
uses: actions/upload-artifact@v4
Expand Down

0 comments on commit 2c53248

Please sign in to comment.