chore: reduce ci usage #3494
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Pact-Rust Build | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref || github.run_id }} | |
cancel-in-progress: true | |
env: | |
RUST_BACKTRACE: "1" | |
RUST_LOG: "debug" | |
PACT_DO_NOT_TRACK: "true" | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ${{ matrix.operating-system }} | |
strategy: | |
fail-fast: false | |
matrix: | |
operating-system: [ ubuntu-latest, windows-latest, macos-13, macos-14 ] | |
rust: [ stable ] | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
components: clippy | |
- uses: taiki-e/install-action@v2 | |
with: | |
tool: cargo-nextest | |
- name: Install shared mime info DB | |
if: runner.os == 'macOS' | |
run: brew install shared-mime-info | |
- name: Tests | |
run: cargo nextest run | |
working-directory: rust | |
- name: Run mock_server_logs test | |
run: cargo nextest run -p pact_ffi returns_mock_server_logs -- --include-ignored | |
working-directory: rust | |
- name: Clippy | |
if: runner.os == 'Linux' | |
run: cargo clippy | |
working-directory: rust | |
musl-build: | |
runs-on: ubuntu-latest | |
container: | |
image: pactfoundation/rust-musl-build | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dtolnay/rust-toolchain@stable | |
with: | |
toolchain: stable | |
components: clippy | |
- uses: taiki-e/install-action@v2 | |
with: | |
tool: cargo-nextest | |
- name: Tests | |
run: cargo nextest run | |
working-directory: rust | |
check-features: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- run: cargo check --no-default-features | |
working-directory: rust |