-
Notifications
You must be signed in to change notification settings - Fork 116
33 lines (30 loc) · 834 Bytes
/
rust.yml
File metadata and controls
33 lines (30 loc) · 834 Bytes
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
name: Rust
on: [push, pull_request]
jobs:
formatting:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Check formatting
run: cargo fmt -- --check
build-test:
runs-on: ubuntu-latest
strategy:
matrix:
# Always run MSRV too!
rust: ["stable", "1.87"]
features: ['log', 'defmt-log', '""']
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
- name: Build
run: cargo build --no-default-features --features ${{matrix.features}} --verbose
env:
DEFMT_LOG: debug
- name: Run Tests
run: cargo test --no-default-features --features ${{matrix.features}} --verbose