Skip to content

[CI] Publish test python package on test.pypi.org #186

[CI] Publish test python package on test.pypi.org

[CI] Publish test python package on test.pypi.org #186

Workflow file for this run

name: Cargo Build & Test
on:
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
build_and_test:
name: Rust project - latest
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
toolchain:
- stable
- beta
- nightly
os:
- ubuntu-latest
- macos-latest
- windows-latest
steps:
- name: Install dependencies
if: ${{ matrix.os == 'ubuntu-latest' }}
run: |
sudo apt-get install -y libfuse-dev
- name: Install dependencies
if: ${{ matrix.os == 'macos-latest'}}
run: |
brew install macfuse
- name: Checkout code
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
components: rustfmt
- name: Check format
run: cargo fmt --all --check
- name: Build
run: cargo build --workspace
- name: Test code
run: cargo test --workspace --verbose --features in_ci
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: binary-${{ matrix.os }}-${{ matrix.toolchain }}
path: |
target/debug/arx
target/debug/arx.exe
target/debug/tar2arx
target/debug/tar2arx.exe
target/debug/zip2arx
target/debug/zip2arx.exe
target/debug/auto_mount
compression-level: 0
compilation_32bits:
name: Test 32 bits compilation
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install cross
run: cargo install cross
- name: Test code
env:
CROSS_CONTAINER_OPTS: "--device /dev/fuse --cap-add SYS_ADMIN"
run: |
cross test --workspace --verbose --target=i686-unknown-linux-gnu --features in_ci --exclude python-libarx