Skip to content
This repository has been archived by the owner on Aug 15, 2024. It is now read-only.

Merge pull request #164 from hi-rustin/rustin-patch-ICE #487

Merge pull request #164 from hi-rustin/rustin-patch-ICE

Merge pull request #164 from hi-rustin/rustin-patch-ICE #487

Workflow file for this run

name: Rust
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
env:
CARGO_TERM_COLOR: always
jobs:
rustfmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Cache cargo registry
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- run: rustup update stable && rustup default stable
- run: rustup component add rustfmt
- run: cargo fmt --all --check
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Cache cargo registry
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- run: rustup update stable && rustup default stable
- run: rustup component add clippy
- run: cargo clippy -- -D warnings
test:
runs-on: ${{ matrix.os }}
env:
CARGO_PROFILE_DEV_DEBUG: 1
CARGO_PROFILE_TEST_DEBUG: 1
CARGO_INCREMENTAL: 0
CARGO_PUBLIC_NETWORK_TESTS: 1
# Deny warnings on CI to avoid warnings getting into the codebase.
RUSTFLAGS: -D warnings
strategy:
matrix:
include:
- name: Linux x86_64 stable
os: ubuntu-latest
rust: stable
- name: Linux x86_64 beta
os: ubuntu-latest
rust: beta
- name: Linux x86_64 nightly
os: ubuntu-latest
rust: nightly-2024-05-01
- name: macOS x86_64 stable
os: macos-latest
rust: stable
- name: macOS x86_64 nightly
os: macos-latest
rust: nightly-2024-05-01
- name: Windows x86_64 MSVC stable
os: windows-latest
rust: stable-msvc
- name: Windows x86_64 gnu nightly # runs out of space while trying to link the test suite
os: windows-latest
rust: nightly-2024-05-01-gnu
name: Tests ${{ matrix.name }}
steps:
- uses: actions/checkout@v4
- name: Cache cargo registry
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- run: rustup update --no-self-update ${{ matrix.rust }} && rustup default ${{ matrix.rust }}
- run: cargo test
- run: cargo build --features=vendored-openssl
if: >
matrix.name == 'Linux x86_64 stable' ||
matrix.name == 'Linux x86_64 beta' ||
matrix.name == 'Linux x86_64 nightly' ||
matrix.name == 'macOS x86_64 stable' ||
matrix.name == 'macOS x86_64 nightly'