mirror of
https://github.com/tokio-rs/tokio.git
synced 2025-10-01 12:20:39 +00:00
ci: make loom tests optional (#4112)
This commit is contained in:
parent
279e8b001a
commit
8e54145c8b
9
.github/labeler.yml
vendored
Normal file
9
.github/labeler.yml
vendored
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
|
||||||
|
R-loom:
|
||||||
|
- ./tokio/src/sync/*
|
||||||
|
- ./tokio/src/sync/**/*
|
||||||
|
- ./tokio-util/src/sync/*
|
||||||
|
- ./tokio-util/src/sync/**/*
|
||||||
|
- ./tokio/src/runtime/*
|
||||||
|
- ./tokio/src/runtime/**/*
|
||||||
|
|
21
.github/workflows/ci.yml
vendored
21
.github/workflows/ci.yml
vendored
@ -27,8 +27,8 @@ jobs:
|
|||||||
- fmt
|
- fmt
|
||||||
- clippy
|
- clippy
|
||||||
- docs
|
- docs
|
||||||
- loom
|
|
||||||
- valgrind
|
- valgrind
|
||||||
|
- loom-compile
|
||||||
- check-readme
|
- check-readme
|
||||||
steps:
|
steps:
|
||||||
- run: exit 0
|
- run: exit 0
|
||||||
@ -300,30 +300,19 @@ jobs:
|
|||||||
RUSTFLAGS: --cfg docsrs
|
RUSTFLAGS: --cfg docsrs
|
||||||
RUSTDOCFLAGS: --cfg docsrs -Dwarnings
|
RUSTDOCFLAGS: --cfg docsrs -Dwarnings
|
||||||
|
|
||||||
loom:
|
loom-compile:
|
||||||
name: loom
|
name: build loom tests
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
scope:
|
|
||||||
- --skip loom_pool
|
|
||||||
- loom_pool::group_a
|
|
||||||
- loom_pool::group_b
|
|
||||||
- loom_pool::group_c
|
|
||||||
- loom_pool::group_d
|
|
||||||
- time::driver
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Install Rust
|
- name: Install Rust
|
||||||
run: rustup update stable
|
run: rustup update stable
|
||||||
- uses: Swatinem/rust-cache@v1
|
- uses: Swatinem/rust-cache@v1
|
||||||
- name: loom ${{ matrix.scope }}
|
- name: build --cfg loom
|
||||||
run: cargo test --lib --release --features full -- --nocapture $SCOPE
|
run: cargo test --no-run --lib --features full
|
||||||
working-directory: tokio
|
working-directory: tokio
|
||||||
env:
|
env:
|
||||||
RUSTFLAGS: --cfg loom --cfg tokio_unstable -Dwarnings
|
RUSTFLAGS: --cfg loom --cfg tokio_unstable -Dwarnings
|
||||||
LOOM_MAX_PREEMPTIONS: 2
|
|
||||||
SCOPE: ${{ matrix.scope }}
|
|
||||||
|
|
||||||
check-readme:
|
check-readme:
|
||||||
name: Check README
|
name: Check README
|
||||||
|
13
.github/workflows/labeler.yml
vendored
Normal file
13
.github/workflows/labeler.yml
vendored
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
name: "Pull Request Labeler"
|
||||||
|
on:
|
||||||
|
- pull_request_target
|
||||||
|
|
||||||
|
# See .github/labeler.yml file
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
triage:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/labeler@v3
|
||||||
|
with:
|
||||||
|
repo-token: "${{ secrets.GITHUB_TOKEN }}"
|
41
.github/workflows/loom.yml
vendored
Normal file
41
.github/workflows/loom.yml
vendored
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: ["master", "tokio-*.x"]
|
||||||
|
pull_request:
|
||||||
|
types: [labeled, opened, synchronize, reopened]
|
||||||
|
branches: ["master", "tokio-*.x"]
|
||||||
|
|
||||||
|
name: Loom
|
||||||
|
|
||||||
|
env:
|
||||||
|
RUSTFLAGS: -Dwarnings
|
||||||
|
RUST_BACKTRACE: 1
|
||||||
|
nightly: nightly-2021-07-09
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
loom:
|
||||||
|
name: loom
|
||||||
|
# base_ref is null when it's not a pull request
|
||||||
|
if: contains(github.event.pull_request.labels.*.name, 'R-loom') || (github.base_ref == null)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
scope:
|
||||||
|
- --skip loom_pool
|
||||||
|
- loom_pool::group_a
|
||||||
|
- loom_pool::group_b
|
||||||
|
- loom_pool::group_c
|
||||||
|
- loom_pool::group_d
|
||||||
|
- time::driver
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Install Rust
|
||||||
|
run: rustup update stable
|
||||||
|
- uses: Swatinem/rust-cache@v1
|
||||||
|
- name: loom ${{ matrix.scope }}
|
||||||
|
run: cargo test --lib --release --features full -- --nocapture $SCOPE
|
||||||
|
working-directory: tokio
|
||||||
|
env:
|
||||||
|
RUSTFLAGS: --cfg loom --cfg tokio_unstable -Dwarnings
|
||||||
|
LOOM_MAX_PREEMPTIONS: 2
|
||||||
|
SCOPE: ${{ matrix.scope }}
|
Loading…
x
Reference in New Issue
Block a user