-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (34 loc) · 988 Bytes
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: build and test CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- run: cargo build
- run: cargo check
- run: cargo fmt
- run: cargo doc --no-deps
- name: save docs as artifact
uses: actions/upload-artifact@v4
with:
name: rf24-rs docs
path: target/doc
- run: rustup component add llvm-tools-preview
- name: Install cargo-nextest and cargo-llvm-cov
uses: taiki-e/install-action@v2
with:
tool: cargo-llvm-cov,cargo-binstall
- name: Run tests
run: cargo llvm-cov --lcov --output-path lcov.info
- uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
files: lcov.info
fail_ci_if_error: true