Skip to content

Commit db13e1c

Browse files
committed
chore: update ci with privileges for running msg-sim tests
1 parent f8b6335 commit db13e1c

File tree

1 file changed

+24
-3
lines changed

1 file changed

+24
-3
lines changed

.github/workflows/ci.yml

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,33 @@ jobs:
3232
- name: Install cargo-nextest
3333
uses: taiki-e/install-action@nextest
3434

35-
- name: Run tests (all features)
36-
run: cargo nextest run --all --all-features --no-fail-fast
35+
- name: Run tests (all features, excluding msg-sim)
36+
run: cargo nextest run --all --all-features --no-fail-fast --exclude msg-sim
3737

38-
- name: Run doc tests
38+
- name: Run doc tests (excluding msg-sim)
3939
run: cargo test --doc --all --all-features
4040

41+
# msg-sim tests require root privileges to create network namespaces
42+
cargo-tests-msg-sim:
43+
runs-on: ubuntu-latest
44+
timeout-minutes: 20
45+
steps:
46+
- name: Checkout sources
47+
uses: actions/checkout@v6
48+
49+
- name: Install Rust toolchain
50+
uses: dtolnay/rust-toolchain@stable
51+
52+
- uses: Swatinem/rust-cache@v2
53+
with:
54+
cache-on-failure: true
55+
56+
- name: Install cargo-nextest
57+
uses: taiki-e/install-action@nextest
58+
59+
- name: Run msg-sim tests (requires root for network namespaces)
60+
run: sudo env "PATH=$PATH" "HOME=$HOME" cargo nextest run -p msg-sim --all-features --no-fail-fast
61+
4162
cargo-lint:
4263
runs-on: ubuntu-latest
4364
timeout-minutes: 20

0 commit comments

Comments
 (0)