Skip to content
This repository has been archived by the owner on Feb 18, 2024. It is now read-only.

Commit

Permalink
Moved coverage reporting to cargo-llvm-cov (#1028)
Browse files Browse the repository at this point in the history
  • Loading branch information
jorgecarleitao committed May 31, 2022
1 parent 7acf301 commit e4a70f8
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 28 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Coverage

on: [pull_request, push]

jobs:
coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true # needed to test IPC, which are located in a submodule
- name: Install Rust
run: rustup toolchain install stable --component llvm-tools-preview
- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov
- name: Setup parquet files
run: |
apt update && apt install python3-pip python3-venv -y -q
python3 -m venv venv
source venv/bin/activate
pip install pip --upgrade
pip install pyarrow==6
python parquet_integration/write_parquet.py
deactivate
- uses: Swatinem/rust-cache@v1
- name: Generate code coverage
run: cargo llvm-cov --features full --lcov --output-path lcov.info
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
files: lcov.info
fail_ci_if_error: true
28 changes: 0 additions & 28 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,34 +111,6 @@ jobs:
- name: Run
run: MIRIFLAGS="-Zmiri-disable-isolation" cargo miri test --tests --features io_ipc,io_json_integration io::ipc::write::write_sliced_list

coverage:
name: Coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install Rust
run: rustup update stable
- name: Setup parquet files
run: |
apt update && apt install python3-pip python3-venv -y -q
python3 -m venv venv
source venv/bin/activate
pip install pip --upgrade
pip install pyarrow==6
python parquet_integration/write_parquet.py
deactivate
- uses: Swatinem/rust-cache@v1
- name: Install tarpaulin
run: cargo install cargo-tarpaulin
- name: Run coverage
run: |
cargo tarpaulin --features full --ignore-tests --out Xml
- name: Report coverage
continue-on-error: true
run: bash <(curl -s https://codecov.io/bash)

feature-compilation:
name: Feature coverage
runs-on: ubuntu-latest
Expand Down

0 comments on commit e4a70f8

Please sign in to comment.