Skip to content

Commit

Permalink
Change github test action
Browse files Browse the repository at this point in the history
  • Loading branch information
Guilospanck committed Mar 17, 2024
1 parent f43ab05 commit 7048383
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,18 @@ jobs:
find . -name '*.gcda' -delete
cargo install grcov --force;
rm -rf lcov.info;
sudo apt install make -y
make test $CARGO_OPTIONS;
zip -0 ccov.zip `find . \( -name "$PROJECT_NAME_UNDERSCORE*.gc*" \) -print`;
grcov ccov.zip -s . -t lcov --llvm --branch --ignore-not-existing --ignore "/*" -o lcov.info;
cargo test --tests $CARGO_OPTIONS;
grcov . \
--branch \
--ignore-not-existing \
--keep-only "src/prices/mod.rs" \
--keep-only "src/blockchain/mod.rs" \
--keep-only "src/lightning/mod.rs" \
--keep-only "tests/*" \
--binary-path ./target/debug/ \
-s . \
-t lcov \
-o lcov.info;
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion generate_coverage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ run_tests() {

run_gcov() {
echo "> Running gcov";
grcov . -s . --binary-path ./target/debug/ -t html --branch --ignore-not-existing --keep-only "src/prices/mod.rs" --keep-only "src/blockchain/mod.rs" --keep-only "src/lightning/mod.rs" --keep-only "tests/*" --ignore "src/blockchain/types" -o ./target/debug/coverage/;
grcov . -s . --binary-path ./target/debug/ -t html --branch --ignore-not-existing --keep-only "src/prices/mod.rs" --keep-only "src/blockchain/mod.rs" --keep-only "src/lightning/mod.rs" --keep-only "tests/*" -o ./target/debug/coverage/;
}

generate_coverage() {
Expand Down

0 comments on commit 7048383

Please sign in to comment.