From 4ff946f8f07148794584946fdc0b9714486e9640 Mon Sep 17 00:00:00 2001 From: Lucas Farias Date: Tue, 20 May 2025 16:05:49 -0300 Subject: [PATCH] CONTENTIOUS: Run tests on linux through xvfb --- .github/workflows/ci.yml | 13 +++++++++++++ .github/workflows/weekly.yml | 13 +++++++++++++ 2 files changed, 26 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2a0610cf03..6245b696aa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,11 +42,24 @@ jobs: - uses: dtolnay/rust-toolchain@stable - name: Install Linux dependencies uses: ./.github/actions/install-linux-deps + # At some point this may be merged into `install-linux-deps`, but for now it is its own step. + - name: Install additional Linux dependencies for Vulkan + if: ${{ runner.os == 'linux' }} + run: | + sudo add-apt-repository ppa:kisak/turtle -y + sudo apt-get install --no-install-recommends libxkbcommon-x11-0 xvfb libgl1-mesa-dri libxcb-xfixes0-dev mesa-vulkan-drivers - name: Build & run tests + if: ${{ runner.os != 'linux' }} # See tools/ci/src/main.rs for the commands this runs run: cargo run -p ci -- test env: RUSTFLAGS: "-C debuginfo=0 -D warnings" + - name: Build & run tests through xvfb + if: ${{ runner.os == 'linux' }} + # See tools/ci/src/main.rs for the commands this runs + run: xvfb-run cargo run -p ci -- test + env: + RUSTFLAGS: "-C debuginfo=0 -D warnings" ci: runs-on: ubuntu-latest diff --git a/.github/workflows/weekly.yml b/.github/workflows/weekly.yml index b4ddffdb9d..60f113eee1 100644 --- a/.github/workflows/weekly.yml +++ b/.github/workflows/weekly.yml @@ -43,11 +43,24 @@ jobs: - uses: dtolnay/rust-toolchain@beta - name: Install Linux dependencies uses: ./.github/actions/install-linux-deps + # At some point this may be merged into `install-linux-deps`, but for now it is its own step. + - name: Install additional Linux dependencies for Vulkan + if: ${{ runner.os == 'linux' }} + run: | + sudo add-apt-repository ppa:kisak/turtle -y + sudo apt-get install --no-install-recommends libxkbcommon-x11-0 xvfb libgl1-mesa-dri libxcb-xfixes0-dev mesa-vulkan-drivers - name: Build & run tests + if: ${{ runner.os != 'linux' }} # See tools/ci/src/main.rs for the commands this runs run: cargo run -p ci -- test env: RUSTFLAGS: "-C debuginfo=0 -D warnings" + - name: Build & run tests through xvfb + if: ${{ runner.os == 'linux' }} + # See tools/ci/src/main.rs for the commands this runs + run: xvfb-run cargo run -p ci -- test + env: + RUSTFLAGS: "-C debuginfo=0 -D warnings" lint: runs-on: ubuntu-latest