From 68298277a7e8c3b718810bfbd8875fa68de29df0 Mon Sep 17 00:00:00 2001 From: Kyle Willmon Date: Tue, 26 Sep 2023 11:07:14 -0500 Subject: [PATCH] Test unshare in GitHub runners --- .github/workflows/test.yml | 45 ++++---------------------------------- 1 file changed, 4 insertions(+), 41 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 757d3d1..f4c132b 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -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