@@ -10,88 +10,62 @@ jobs:
1010 name : Test
1111 runs-on : ubuntu-latest
1212 steps :
13- - uses : actions/checkout@v2
14- - uses : actions-rs/toolchain@v1
15- with :
16- profile : minimal
17- toolchain : stable
18- override : true
19- - uses : Swatinem/rust-cache@v1
20- - uses : actions-rs/cargo@v1
21- with :
22- command : test
13+ - uses : actions/checkout@v5
14+ - name : Install Rust stable toolchain
15+ uses :
actions-rust-lang/[email protected] 16+ - name : Document
17+ run : |
18+ cargo test
2319
2420 fmt :
2521 name : Rustfmt
2622 runs-on : ubuntu-latest
2723 steps :
28- - uses : actions/checkout@v2
29- - uses : actions-rs/toolchain@v1
30- with :
31- profile : minimal
32- toolchain : stable
33- override : true
34- components : rustfmt
35- - uses : Swatinem/rust-cache@v1
36- - uses : actions-rs/cargo@v1
37- with :
38- command : fmt
39- args : --all -- --check
24+ - uses : actions/checkout@v5
25+ - name : Install Rust stable toolchain
26+ uses :
actions-rust-lang/[email protected] 27+ - name : Document
28+ run : |
29+ cargo fmt --all -- --check
4030
4131 clippy :
4232 name : Clippy
4333 runs-on : ubuntu-latest
4434 steps :
4535 - name : Checkout repository
46- uses : actions/checkout@v2
47- - uses : actions-rs/toolchain@v1
48- with :
49- profile : minimal
50- toolchain : stable
51- override : true
52- components : clippy
53- - uses : Swatinem/rust-cache@v1
54- - uses : actions-rs/cargo@v1
55- with :
56- command : clippy
57- args : -- -D warnings
36+ uses : actions/checkout@v5
37+ - name : Install Rust stable toolchain
38+ uses :
actions-rust-lang/[email protected] 39+ - name : Document
40+ run : |
41+ cargo clippy -- -D warnings
5842
5943 docs :
6044 name : Docs
6145 runs-on : ubuntu-latest
6246 steps :
6347 - name : Checkout repository
64- uses : actions/checkout@v2
65- - name : Install Rust
66- uses : actions-rs/toolchain@v1
67- with :
68- toolchain : stable
69- profile : minimal
70- override : true
71- - uses : Swatinem/rust-cache@v1
72- - name : Check documentation
73- env :
74- RUSTDOCFLAGS : -D warnings
75- uses : actions-rs/cargo@v1
76- with :
77- command : doc
78- args : --no-deps --document-private-items
48+ uses : actions/checkout@v5
49+ - name : Install Rust stable toolchain
50+ uses :
actions-rust-lang/[email protected] 51+ - name : Document
52+ run : |
53+ cargo doc --no-deps --document-private-items
7954
8055 coverage :
81- name : Code coverage
8256 runs-on : ubuntu-latest
57+ env :
58+ CARGO_TERM_COLOR : always
8359 steps :
84- - name : Checkout repository
85- uses : actions/checkout@v2
86-
87- - name : Install stable toolchain
88- uses : actions-rs/toolchain@v1
89- with :
90- toolchain : stable
91- override : true
92-
93- - uses : Swatinem/rust-cache@v1
94- - name : Run cargo-tarpaulin
95- uses :
actions-rs/[email protected] 60+ - uses : actions/checkout@v5
61+ - name : Install Rust stable toolchain
62+ uses :
actions-rust-lang/[email protected] 63+ - name : Install cargo-llvm-cov
64+ uses : taiki-e/install-action@cargo-llvm-cov
65+ - name : Generate code coverage
66+ run : cargo llvm-cov --all-features --workspace --codecov --output-path codecov.json
67+ - name : Upload coverage to Codecov
68+ uses : codecov/codecov-action@v3
9669 with :
97- args : ' --ignore-tests'
70+ files : codecov.json
71+ fail_ci_if_error : true
0 commit comments