Skip to content

Commit

Permalink
ci: add code coverage support
Browse files Browse the repository at this point in the history
Signed-off-by: wanglei01 <[email protected]>
  • Loading branch information
wllenyj committed Oct 20, 2022
1 parent 77b0736 commit 65d0ed5
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,16 @@ jobs:
with:
toolchain: stable
override: true
components: cargo, llvm-tools-preview

- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov

- name: Test and Generate code coverage
run: cargo llvm-cov --all-features --workspace --lcov --output-path lcov.info
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: lcov.info
fail_ci_if_error: true

- name: Test with default feature
run: cargo test

0 comments on commit 65d0ed5

Please sign in to comment.