mirror of
https://github.com/n0-computer/noq.git
synced 2026-09-21 02:33:23 +00:00
80 lines
1.8 KiB
YAML
80 lines
1.8 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: ['master', '0.5.x']
|
|
pull_request:
|
|
|
|
jobs:
|
|
test:
|
|
strategy:
|
|
matrix:
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
rust: [stable, beta]
|
|
exclude:
|
|
- os: macos-latest
|
|
rust: beta
|
|
- os: windows-latest
|
|
rust: beta
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- uses: actions-rs/toolchain@v1
|
|
with:
|
|
profile: minimal
|
|
toolchain: ${{ matrix.rust }}
|
|
override: true
|
|
- uses: actions-rs/cargo@v1
|
|
with:
|
|
command: build
|
|
args: --workspace --all-targets
|
|
- uses: actions-rs/cargo@v1
|
|
with:
|
|
command: test
|
|
args: --workspace
|
|
|
|
lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- uses: actions-rs/toolchain@v1
|
|
with:
|
|
profile: minimal
|
|
toolchain: stable
|
|
override: true
|
|
components: rustfmt, clippy
|
|
- uses: actions-rs/cargo@v1
|
|
with:
|
|
command: fmt
|
|
args: --all -- --check
|
|
- uses: actions-rs/cargo@v1
|
|
if: always()
|
|
with:
|
|
command: clippy
|
|
args: --workspace --all-targets -- -D warnings
|
|
|
|
coverage:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: nightly
|
|
override: true
|
|
- uses: actions-rs/tarpaulin@v0.1
|
|
- uses: codecov/codecov-action@v1.0.2
|
|
with:
|
|
token: ${{secrets.CODECOV_TOKEN}}
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: code-coverage-report
|
|
path: cobertura.xml
|
|
|
|
audit:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- uses: EmbarkStudios/cargo-deny-action@v0
|