1
0
mirror of https://github.com/fafhrd91/actix-web synced 2024-11-30 18:44:35 +01:00
actix-web/.github/workflows/coverage.yml

40 lines
896 B
YAML
Raw Normal View History

2022-03-10 17:17:49 +01:00
name: Coverage
on:
push:
branches: [master]
2023-03-15 14:32:55 +01:00
permissions:
2023-08-03 08:03:42 +02:00
contents: read
2023-03-15 14:32:55 +01:00
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
2022-03-10 17:17:49 +01:00
jobs:
coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
2023-09-12 06:24:55 +02:00
2023-08-03 07:58:31 +02:00
- name: Install Rust
uses: actions-rust-lang/setup-rust-toolchain@v1.8.0
2023-08-03 07:58:31 +02:00
with:
components: llvm-tools-preview
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@v2.33.22
2023-08-03 07:58:31 +02:00
with:
tool: cargo-llvm-cov
2022-03-10 17:17:49 +01:00
2023-08-03 07:58:31 +02:00
- name: Generate code coverage
run: cargo llvm-cov --workspace --all-features --codecov --output-path codecov.json
2022-03-10 17:17:49 +01:00
2023-08-03 07:58:31 +02:00
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4.3.1
with:
2023-08-03 07:58:31 +02:00
files: codecov.json
fail_ci_if_error: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}