name: CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
env:
CARGO_TERM_COLOR: always
jobs:
check-fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Check formatting
run: cargo fmt -- --check
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install clippy
run: rustup component add clippy
- name: Run clippy
run: cargo clippy
test:
name: Build and Test stable features
runs-on: ubuntu-latest
strategy:
matrix:
rust: [stable, nightly]
steps:
- uses: actions/checkout@v2
- name: Build
run: cargo build --verbose
- name: Test
run: cargo test --verbose
- name: Build with serde and io
run: cargo build --verbose --features="serde_all io"
- name: Test with serde and io
run: cargo test --verbose --features="serde_all io"
- name: Build with rayon
run: cargo build --verbose --no-default-features --features="rayon"
- name: Test with rayon
run: cargo test --verbose --no-default-features --features="rayon"
- name: Build with serde, io and rayon
run: cargo build --verbose --features="serde_all io rayon"
- name: Test with serde, io and rayon
run: cargo test --verbose --features="serde_all io rayon"
test_all_features:
name: Build and Test all features
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
override: true
- name: Build
run: cargo build --verbose --all-features
- name: Test
run: cargo test --verbose --all-features