Skip to content

Commit

Permalink
ci: Make sure the same Cargo version is used
Browse files Browse the repository at this point in the history
Set and export the CARGO environment variable to make sure the
ubuntu_22_rust_stable job uses a consistent Cargo version for
landlock-test-tools/test-rust.sh tests and the native test.

Signed-off-by: Mickaël Salaün <[email protected]>
  • Loading branch information
l0kod committed Aug 30, 2023
1 parent e44d539 commit 91d7f4d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ jobs:
commit: ${{ fromJSON(needs.commit_list.outputs.commits) }}
env:
LANDLOCK_CRATE_TEST_ABI: 1
# $CARGO is used by landlock-test-tools/test-rust.sh
CARGO: rustup run stable cargo
steps:
- name: Install Rust stable
run: |
Expand All @@ -130,15 +132,15 @@ jobs:
ref: ${{ matrix.commit }}

- name: Run tests
run: rustup run stable cargo test --verbose
run: $CARGO test --verbose

- name: Clone Landlock test tools
uses: actions/checkout@v3
with:
repository: landlock-lsm/landlock-test-tools
path: landlock-test-tools
fetch-depth: 0
ref: ab616e087cffa4b6716ff026e589d0317e19aaa4 # v1.0.0
ref: test

- name: Run tests against Linux 5.10
run: ./landlock-test-tools/test-rust.sh linux-5.10 0
Expand Down

0 comments on commit 91d7f4d

Please sign in to comment.