Trying macos #375
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: CI Build | |
on: [push] | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Disable autocrlf (Windows) | |
if: runner.os == 'Windows' | |
run: git config --global core.autocrlf false | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
lfs: true | |
# There should be no need to install Rustup or a Rust toolchain explicitly. | |
# The `ubuntu-22.04` image already includes Rustup: | |
# <https://github.com/actions/runner-images/blob/ubuntu22/20240401.4/images/ubuntu/Ubuntu2204-Readme.md#rust-tools> | |
# Running `rustc` or Cargo should automatically install the toolchain specified in `rust-toolchain.toml`. | |
- uses: Swatinem/rust-cache@v2 | |
- name: Run cargo build | |
run: cargo build --release --features default-networks | |
- name: Check if code is formatted (Linux) | |
if: runner.os == 'Linux' | |
run: cargo fmt --check | |
- name: Run Clippy (Linux) | |
if: runner.os == 'Linux' | |
run: scripts/ci/clippy.bash --deny warnings | |
# It's a known issue that a couple of networking tests doesn't pass | |
- name: Run tests | |
if: runner.os == 'Macos' | |
run: cargo test --release --no-fail-fast -- --skip behaviour | |
#run: cargo test --release --no-fail-fast -- --skip behaviour::tests::test_scoring_p1 --skip behaviour::tests::test_scoring_p7_grafts_before_backoff | |
- name: Run tests | |
if: runner.os != 'Macos' | |
run: cargo test --release --no-fail-fast | |
- name: Check consensus-spec-tests coverage (Linux) | |
if: runner.os == 'Linux' | |
run: scripts/ci/consensus-spec-tests-coverage.rb |