mirror of
https://github.com/pesde-pkg/pesde.git
synced 2024-12-12 19:10:35 +00:00
40 lines
No EOL
1 KiB
YAML
40 lines
No EOL
1 KiB
YAML
name: Test & Lint
|
|
on:
|
|
- push
|
|
- pull_request
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
|
|
jobs:
|
|
lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Set up Rust
|
|
uses: moonrepo/setup-rust@v1
|
|
with:
|
|
bins: cargo-tarpaulin
|
|
components: rustfmt, clippy
|
|
|
|
- name: Install OS dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y libssl-dev
|
|
|
|
- name: Run tests
|
|
run: cargo test --all --all-features
|
|
|
|
- name: Check formatting
|
|
run: cargo fmt --all -- --check
|
|
|
|
- name: Run clippy
|
|
run: cargo clippy --all --all-targets --all-features -- -D warnings
|
|
|
|
- name: Generate coverage report
|
|
run: cargo tarpaulin --all-features --out xml --exclude-files src/cli/* --exclude-files registry/* --exclude-files src/main.rs --skip-clean
|
|
|
|
- name: Upload coverage reports to Codecov
|
|
uses: codecov/codecov-action@v4.0.1
|
|
with:
|
|
token: ${{ secrets.CODECOV_TOKEN }} |