Skip to content

Codecov

Codecov #80

Workflow file for this run

name: Tests
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
env:
CARGO_TERM_COLOR: always
jobs:

Check failure on line 12 in .github/workflows/tests.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/tests.yml

Invalid workflow file

You have an error in your yaml syntax on line 12
build:
runs-on: ubuntu-latest
name: Tests on rust toolchain ${{ matrix.version }}
strategy:
matrix:
version: [
"nightly",
"stable",
"1.70",
"1.56", # 2021 edition
]
steps:
- uses: actions/checkout@v3
- name: Build
run: |
rustup toolchain install nightly
cargo +nightly -Zscript ./pre-publish.rs
rustup toolchain install ${{ matrix.version }}
cargo build
- name: Run tests
run: cargo test --verbose
- name: Run no-std tests
run: cargo test --verbose --no-default-features
- name: Run serde tests
run: cargo test --verbose --test 'serde' --features serde
- name: Run no-std+serde tests
run: cargo test --verbose --test 'serde' --no-default-features --features serde
codecov:
- uses: actions/checkout@v3
- name: Build
run: |
rustup toolchain install nightly
cargo +nightly -Zscript ./pre-publish.rs
rustup toolchain install ${{ matrix.version }}
cargo build
- name: Run tests on with all features for Codecov
run: cargo test --all-features
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
clippy:
runs-on: ubuntu-latest
name: Clippy
steps:
- uses: actions/checkout@v3
- run: |
rustup toolchain install nightly
cargo +nightly -Zscript ./pre-publish.rs
cargo clippy --verbose