Skip to content

Commit

Permalink
Use cargo-llvm-cov instead
Browse files Browse the repository at this point in the history
  • Loading branch information
TSnake41 committed Aug 18, 2023
1 parent f3567d9 commit ad0b252
Showing 1 changed file with 10 additions and 14 deletions.
24 changes: 10 additions & 14 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,22 +22,18 @@ jobs:
- name: Build
run: cargo build --verbose

- name: Code coverage
uses: actions-rs/tarpaulin@v0.1.0
with:
version: "0.22.0"
args: '-- -p xcp-metrics-common xcp-metrics'
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov

- name: Upload to codecov.io
uses: codecov/codecov-action@v1.0.2
with:
token: ${{secrets.CODECOV_TOKEN}}

- name: Archive code coverage results
uses: actions/upload-artifact@v1
- name: 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:
name: code-coverage-report
path: cobertura.xml
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
files: lcov.info
fail_ci_if_error: true

- name: Run tests
run: cargo test --verbose

0 comments on commit ad0b252

Please sign in to comment.