Skip to content

Merge pull request #3 from dfialho/main #17

Merge pull request #3 from dfialho/main

Merge pull request #3 from dfialho/main #17

Workflow file for this run

name: CI
on:
pull_request:
push:
branches:
- main
env:
RUST_BACKTRACE: 1
jobs:
style:
name: Check Style
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
components: rustfmt
- name: cargo fmt --check
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
check_features:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
- uses: taiki-e/install-action@cargo-hack
- run: cargo hack check --each-feature
test:
name: Test ${{ matrix.rust }} on ${{ matrix.os }}
needs: [style]
strategy:
matrix:
rust:
- stable
- beta
- nightly
os:
- ubuntu-latest
- windows-latest
- macOS-latest
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install Rust (${{ matrix.rust }})
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
- name: Test
uses: actions-rs/cargo@v1
with:
command: test
args: --features serde