Skip to content

Commit

Permalink
merge lcov separately, to be able to pass separate binary-path to grc…
Browse files Browse the repository at this point in the history
…ov for unit tests and python binding
  • Loading branch information
arvidn committed Apr 16, 2021
1 parent 8e9874a commit 1899311
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ jobs:
python -m pip install colorama
python -m pip install maturin
python -m pip install pytest
apt install lcov
rustup target add x86_64-unknown-linux-musl
cargo install grcov
Expand All @@ -66,8 +67,14 @@ jobs:
run: |
. ./activate
LLVM_PROFILE_FILE="pytest.profraw" pytest clvm/tests
grcov . -s . --binary-path ./venv/lib/python3.9/site-packages/ -t lcov --branch --ignore-not-existing -o pytest.lcov.info --keep-only src
rm pytest.profraw
LLVM_PROFILE_FILE="unittest.profraw" RUSTFLAGS="-Zinstrument-coverage" cargo test --no-default-features
grcov . -s . --binary-path ./venv/lib/python3.9/site-packages/ -t lcov --branch --ignore-not-existing -o lcov.info --keep-only src
grcov . -s . --binary-path ./target/debug/build -t lcov --branch --ignore-not-existing -o unittest.lcov.info --keep-only src
# merge the lcov files
lcov unittest.lcov.info pytest.lcov.info -o lcov.info
- name: Coveralls
uses: coverallsapp/github-action@master
Expand Down
6 changes: 0 additions & 6 deletions src/int_allocator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,6 @@ pub struct IntAllocator {
atom_vec: Vec<IntAtomBuf>,
}

impl Default for IntAllocator {
fn default() -> Self {
Self::new()
}
}

impl IntAllocator {
pub fn new() -> Self {
let mut r = IntAllocator {
Expand Down

0 comments on commit 1899311

Please sign in to comment.