Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to cargo-llvm-cov as coverage provider #134

Merged
merged 1 commit into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,9 +123,10 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- run: cargo install --force cargo-tarpaulin
- run: cargo tarpaulin --all-features --workspace --engine llvm -o Xml
- uses: taiki-e/install-action@cargo-llvm-cov
- run: cargo llvm-cov --all-features --workspace --lcov --output-path lcov.info
- uses: codecov/codecov-action@v3
with:
token: ${{secrets.CODECOV_TOKEN}}
files: lcov.info
fail_ci_if_error: true
16 changes: 8 additions & 8 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@

* All code submitted to RingChannel via pull requests is
assumed to be [licensed under the MIT][LICENSE].
* Every code change must be covered by unit tests, use [tarpaulin] to generate the code coverage report:
+ `cargo +nightly tarpaulin -v --all-features`
* Every code change must be covered by unit tests, use [cargo-llvm-cov] to generate the code coverage report:
+ `cargo llvm-cov --all-features --workspace --lcov --output-path lcov.info`
* Besides `cargo test`, make sure [Clippy] and [rustfmt] checks also pass before submitting a pull request:
+ `cargo clippy --all-targets -- -D warnings`
+ `cargo fmt --all -- --check`
* Follow [rustsec.org] advisories when introducing new dependencies, use [cargo-audit] to verify:
+ `cargo audit -D`

[LICENSE]: https://github.com/brunocodutra/ring-channel/blob/master/LICENSE
[rustsec.org]: https://rustsec.org/advisories/
[LICENSE]: https://github.com/brunocodutra/ring-channel/blob/master/LICENSE
[rustsec.org]: https://rustsec.org/advisories/

[Clippy]: https://github.com/rust-lang/rust-clippy#usage
[rustfmt]: https://github.com/rust-lang/rustfmt#quick-start
[tarpaulin]: https://github.com/xd009642/tarpaulin#usage
[cargo-audit]: https://github.com/RustSec/cargo-audit#installation
[Clippy]: https://github.com/rust-lang/rust-clippy#usage
[rustfmt]: https://github.com/rust-lang/rustfmt#quick-start
[cargo-llvm-cov]: https://github.com/taiki-e/cargo-llvm-cov#usage
[cargo-audit]: https://github.com/RustSec/cargo-audit#installation
2 changes: 0 additions & 2 deletions benches/throughput.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
#![cfg(not(tarpaulin))]

use criterion::measurement::{Measurement, WallTime};
use criterion::{criterion_group, criterion_main, BenchmarkGroup, Criterion, Throughput};
use futures::future::{try_join, try_join_all};
Expand Down
1 change: 0 additions & 1 deletion fuzz/fuzzer.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
#![cfg(not(tarpaulin))]
#![no_main]

use futures::{future::*, prelude::*, stream::*};
Expand Down
Loading