diff --git a/.github/workflows/Test.yml b/.github/workflows/Test.yml index 8ce2925..245d410 100644 --- a/.github/workflows/Test.yml +++ b/.github/workflows/Test.yml @@ -27,10 +27,22 @@ jobs: python -m pip install --upgrade pip pip install pytest pip install maturin + - name: Install cargo-llvm-cov + uses: taiki-e/install-action@cargo-llvm-cov - name: Build and install wheel run: | + source <(cargo llvm-cov show-env --export-prefix) maturin build --out dist --find-interpreter pip install autosar-data --find-links dist - name: Test with pytest run: | - pytest \ No newline at end of file + pytest + - name: Collect test coverage data + run: | + cargo llvm-cov report --lcov --output-path lcov.info + - name: Upload coverage reports to Codecov + uses: codecov/codecov-action@v3 + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + with: + files: lcov.info