Skip to content

Commit

Permalink
Test unshare in GitHub runners
Browse files Browse the repository at this point in the history
  • Loading branch information
kylewillmon committed Sep 26, 2023
1 parent b940485 commit 6829827
Showing 1 changed file with 4 additions and 41 deletions.
45 changes: 4 additions & 41 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,46 +11,9 @@ on:

jobs:
test-matrix:
strategy:
fail-fast: false
matrix:
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
- target: aarch64-unknown-linux-gnu
os: [self-hosted, linux, arm64]
- target: x86_64-apple-darwin
os: macos-latest
- target: aarch64-apple-darwin
os: [self-hosted, macos, arm64]
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.target }}
profile: minimal

- name: Test Stable
run: cargo test

- name: Test Oldstable
run: |
oldstable=$(cat Cargo.toml | grep rust-version | sed 's/.*"\(.*\)".*/\1/')
rustup toolchain install --profile minimal $oldstable
rustup default $oldstable
cargo test
- name: Clippy
run: |
rustup component add clippy
cargo clippy
- name : Rustfmt
- name: Unshare test
run: |
rustup toolchain install nightly -c rustfmt
cargo +nightly fmt -- --check
ls -nd $HOME /etc
unshare -r -- ls -nd $HOME /etc

0 comments on commit 6829827

Please sign in to comment.