Skip to content

Commit 15b6f5b

Browse files
committed
Merge #247: CI: Replace Coveralls with Codecov for coverage reporting
a675935 CI: Update code coverage to use Codecov action (Vihiga Tyonum) Pull request description: <!-- You can erase any parts of this template not applicable to your Pull Request. --> ### Description This PR updates the code_coverage workflow by replacing the Coveralls code coverage reports with codecov. It also updates the checkout, rust-lang toolchain setup actions. Fixes #245 <!-- Describe the purpose of this PR, what's being adding and/or fixed --> ### Notes to the reviewers <!-- In this section you can include notes directed to the reviewers, like explaining why some parts of the PR were done in a specific way --> ## Changelog notice <!-- Notice the release manager should include in the release tag message changelog --> <!-- See https://keepachangelog.com/en/1.0.0/ for examples --> ### Checklists #### All Submissions: * [x] I've signed all my commits * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md) * [x] I ran `cargo fmt` and `cargo clippy` before committing ACKs for top commit: notmandatory: ACK a675935 Tree-SHA512: 021e17bfec6b4c022b8908f2dc4588c3f9f809893d2c6599a073fa943d7caf96a46a47fc9bc54af701b003b95d0b4e1474e9c30fdb533570b3a1d8791f430ba7
2 parents 212df6a + a675935 commit 15b6f5b

File tree

1 file changed

+12
-15
lines changed

1 file changed

+12
-15
lines changed

.github/workflows/code_coverage.yml

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -13,32 +13,29 @@ jobs:
1313

1414
steps:
1515
- name: Checkout
16-
uses: actions/checkout@v4
16+
uses: actions/checkout@v6
1717
with:
1818
persist-credentials: false
19-
- name: Install lcov tools
20-
run: sudo apt-get install lcov -y
2119
- name: Install Rust toolchain
22-
uses: actions-rs/toolchain@v1
20+
uses: actions-rust-lang/setup-rust-toolchain@v1
2321
with:
2422
toolchain: stable
25-
override: true
26-
profile: minimal
2723
components: llvm-tools-preview
28-
- name: Rust Cache
29-
uses: Swatinem/rust-cache@v2.7.8
3024
- name: Install grcov
31-
run: if [[ ! -e ~/.cargo/bin/grcov ]]; then cargo install grcov; fi
25+
run: command -v grcov || cargo install grcov
3226
- name: Test
3327
run: cargo test --all-features
34-
- name: Make coverage directory
35-
run: mkdir coverage
3628
- name: Run grcov
37-
run: grcov . --binary-path ./target/debug/ -s . -t lcov --branch --ignore-not-existing --keep-only 'src/**' --ignore 'tests/**' -o ./coverage/lcov.info
29+
run: |
30+
mkdir -p coverage
31+
grcov . --binary-path ./target/debug/ -s . -t lcov --branch --ignore-not-existing --keep-only 'src/**' --ignore 'tests/**' -o ./coverage/lcov.info
3832
- name: Check lcov.info
3933
run: cat ./coverage/lcov.info
40-
- name: Coveralls
41-
uses: coverallsapp/github-action@v2
34+
- name: Upload to Codecov
35+
uses: codecov/codecov-action@v5
4236
with:
4337
github-token: ${{ secrets.GITHUB_TOKEN }}
44-
file: ./coverage/lcov.info
38+
files: ./coverage/lcov.info
39+
fail_ci_if_error: false
40+
flags: rust
41+

0 commit comments

Comments
 (0)