Skip to content

Commit

Permalink
Update test.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
radumarias authored May 26, 2024
1 parent 7ab3e9a commit 32f7a9d
Showing 1 changed file with 13 additions and 15 deletions.
28 changes: 13 additions & 15 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,28 +16,26 @@ jobs:
- uses: actions/checkout@v4
- name: Set default nightly
run: rustup default nightly && rustup update
- name: Install cargo-tarpaulin
run: cargo install cargo-tarpaulin
- name: Build
run: cargo build --all --verbose
- name: Run tests
run: cargo test --tests --lib --verbose -- --show-output --nocapture
- name: Run doctests
run: cargo test --package rencfs --doc --verbose -- --show-output --nocapture
- name: kcov
run: |
wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz &&
tar xzf master.tar.gz &&
cd kcov-master &&
mkdir build &&
cd build &&
cmake .. &&
make &&
make install DESTDIR=../../kcov-build &&
cd ../.. &&
rm -rf kcov-master &&
for file in target/debug/examplerust-*; do [ -x "${file}" ] || continue; mkdir -p "target/cov/$(basename $file)"; ./kcov-build/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done &&
bash <(curl -s https://codecov.io/bash) &&
echo "Uploaded code coverage"
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}
- name: Run tests with coverage
run: cargo tarpaulin --out Xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v2
with:
files: ./cobertura.xml
flags: unittests
name: codecov-umbrella
fail_ci_if_error: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 32f7a9d

Please sign in to comment.