mirror of
https://github.com/niri-wm/niri.git
synced 2026-06-22 02:01:55 +07:00
CI: Move feature combinations off the docs critical path
Make docs deploy faster. Also don't build --release separately, it's covered by the randomized-tests job.
This commit is contained in:
+50
-37
@@ -8,25 +8,17 @@ on:
|
|||||||
- cron: '0 0 1 * *' # Monthly
|
- cron: '0 0 1 * *' # Monthly
|
||||||
|
|
||||||
env:
|
env:
|
||||||
RUN_SLOW_TESTS: 1
|
|
||||||
DEPS_APT: curl gcc clang libudev-dev libgbm-dev libxkbcommon-dev libegl1-mesa-dev libwayland-dev libinput-dev libdbus-1-dev libsystemd-dev libseat-dev libpipewire-0.3-dev libpango1.0-dev libdisplay-info-dev
|
DEPS_APT: curl gcc clang libudev-dev libgbm-dev libxkbcommon-dev libegl1-mesa-dev libwayland-dev libinput-dev libdbus-1-dev libsystemd-dev libseat-dev libpipewire-0.3-dev libpango1.0-dev libdisplay-info-dev
|
||||||
DEPS_DNF: cargo gcc clang libudev-devel libgbm-devel libxkbcommon-devel wayland-devel libinput-devel dbus-devel systemd-devel libseat-devel pipewire-devel pango-devel cairo-gobject-devel libdisplay-info-devel
|
DEPS_DNF: cargo gcc clang libudev-devel libgbm-devel libxkbcommon-devel wayland-devel libinput-devel dbus-devel systemd-devel libseat-devel pipewire-devel pango-devel cairo-gobject-devel libdisplay-info-devel
|
||||||
DEPS_APK: cargo clang-libclang eudev-dev glib-dev libdisplay-info-dev libinput-dev libseat-dev libxkbcommon-dev mesa-dev pango-dev pipewire-dev tar
|
DEPS_APK: cargo clang-libclang eudev-dev glib-dev libdisplay-info-dev libinput-dev libseat-dev libxkbcommon-dev mesa-dev pango-dev pipewire-dev tar
|
||||||
DEPS_PKG: git curl rust llvm pkgconf pixman libudev-devd libdisplay-info seatd libinput libxkbcommon pipewire mesa-libs cairo devel/glib20 gettext-runtime harfbuzz pango
|
DEPS_PKG: git curl rust llvm pkgconf pixman libudev-devd libdisplay-info seatd libinput libxkbcommon pipewire mesa-libs cairo devel/glib20 gettext-runtime harfbuzz pango
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
test:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
|
|
||||||
matrix:
|
name: test
|
||||||
configuration: [debug, release]
|
|
||||||
|
|
||||||
include:
|
|
||||||
- configuration: release
|
|
||||||
release-flag: '--release'
|
|
||||||
|
|
||||||
name: test - ${{ matrix.configuration }}
|
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@@ -42,35 +34,54 @@ jobs:
|
|||||||
- uses: dtolnay/rust-toolchain@stable
|
- uses: dtolnay/rust-toolchain@stable
|
||||||
|
|
||||||
- uses: Swatinem/rust-cache@v2
|
- uses: Swatinem/rust-cache@v2
|
||||||
with:
|
|
||||||
key: ${{ matrix.configuration }}
|
|
||||||
|
|
||||||
- name: Check (no default features)
|
|
||||||
run: cargo check ${{ matrix.release-flag }} --no-default-features
|
|
||||||
|
|
||||||
- name: Check (just dbus)
|
|
||||||
run: cargo check ${{ matrix.release-flag }} --no-default-features --features dbus
|
|
||||||
|
|
||||||
- name: Check (just systemd)
|
|
||||||
run: cargo check ${{ matrix.release-flag }} --no-default-features --features systemd
|
|
||||||
|
|
||||||
- name: Check (just dinit)
|
|
||||||
run: cargo check ${{ matrix.release-flag }} --no-default-features --features dinit
|
|
||||||
|
|
||||||
- name: Check (just xdp-gnome-screencast)
|
|
||||||
run: cargo check ${{ matrix.release-flag }} --no-default-features --features xdp-gnome-screencast
|
|
||||||
|
|
||||||
- name: Check
|
|
||||||
run: cargo check ${{ matrix.release-flag }}
|
|
||||||
|
|
||||||
- name: Build (with profiling)
|
|
||||||
run: cargo build ${{ matrix.release-flag }} --features profile-with-tracy
|
|
||||||
|
|
||||||
- name: Build tests
|
- name: Build tests
|
||||||
run: cargo test --no-run --all --exclude niri-visual-tests ${{ matrix.release-flag }}
|
run: cargo test --no-run --all --exclude niri-visual-tests
|
||||||
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: cargo test --all --exclude niri-visual-tests ${{ matrix.release-flag }} -- --nocapture
|
run: cargo test --all --exclude niri-visual-tests -- --nocapture
|
||||||
|
|
||||||
|
build:
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
|
||||||
|
name: check feature combinations
|
||||||
|
runs-on: ubuntu-24.04
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
show-progress: false
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
sudo apt-get update -y
|
||||||
|
sudo apt-get install -y ${{ env.DEPS_APT }}
|
||||||
|
|
||||||
|
- uses: dtolnay/rust-toolchain@stable
|
||||||
|
|
||||||
|
- uses: Swatinem/rust-cache@v2
|
||||||
|
|
||||||
|
- name: Check (no default features)
|
||||||
|
run: cargo check --no-default-features
|
||||||
|
|
||||||
|
- name: Check (just dbus)
|
||||||
|
run: cargo check --no-default-features --features dbus
|
||||||
|
|
||||||
|
- name: Check (just systemd)
|
||||||
|
run: cargo check --no-default-features --features systemd
|
||||||
|
|
||||||
|
- name: Check (just dinit)
|
||||||
|
run: cargo check --no-default-features --features dinit
|
||||||
|
|
||||||
|
- name: Check (just xdp-gnome-screencast)
|
||||||
|
run: cargo check --no-default-features --features xdp-gnome-screencast
|
||||||
|
|
||||||
|
- name: Check
|
||||||
|
run: cargo check
|
||||||
|
|
||||||
|
- name: Build (with profiling)
|
||||||
|
run: cargo build --features profile-with-tracy
|
||||||
|
|
||||||
build-musl:
|
build-musl:
|
||||||
strategy:
|
strategy:
|
||||||
@@ -93,15 +104,17 @@ jobs:
|
|||||||
run: cargo build --no-default-features --features dbus,xdp-gnome-screencast
|
run: cargo build --no-default-features --features dbus,xdp-gnome-screencast
|
||||||
|
|
||||||
# Job that runs randomized tests for a longer period of time.
|
# Job that runs randomized tests for a longer period of time.
|
||||||
|
# Also runs normal slow tests.
|
||||||
randomized-tests:
|
randomized-tests:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
|
|
||||||
name: randomized tests
|
name: randomized and slow tests
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
|
|
||||||
env:
|
env:
|
||||||
RUST_BACKTRACE: 1
|
RUST_BACKTRACE: 1
|
||||||
|
RUN_SLOW_TESTS: 1
|
||||||
PROPTEST_CASES: 200000
|
PROPTEST_CASES: 200000
|
||||||
PROPTEST_MAX_LOCAL_REJECTS: 200000
|
PROPTEST_MAX_LOCAL_REJECTS: 200000
|
||||||
PROPTEST_MAX_GLOBAL_REJECTS: 200000
|
PROPTEST_MAX_GLOBAL_REJECTS: 200000
|
||||||
@@ -311,7 +324,7 @@ jobs:
|
|||||||
publish-docs:
|
publish-docs:
|
||||||
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
|
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
|
||||||
needs:
|
needs:
|
||||||
- build
|
- test
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
runs-on: ubuntu-24.04
|
runs-on: ubuntu-24.04
|
||||||
|
|||||||
Reference in New Issue
Block a user