From aac42fa8e39dc65d05eb5e8b375b3d5112197326 Mon Sep 17 00:00:00 2001 From: Bartek Tofel Date: Wed, 14 Aug 2024 12:50:18 +0200 Subject: [PATCH] prune lcov report in artifact pipeline --- .github/workflows/solidity-foundry-artifacts.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/solidity-foundry-artifacts.yml b/.github/workflows/solidity-foundry-artifacts.yml index 8161aa9f549..733357c323c 100644 --- a/.github/workflows/solidity-foundry-artifacts.yml +++ b/.github/workflows/solidity-foundry-artifacts.yml @@ -214,11 +214,18 @@ jobs: env: FOUNDRY_PROFILE: ${{ inputs.product }} + - name: Prune lcov report + if: ${{ !contains(fromJson(steps.prepare-exclusion-list.outputs.coverage_exclusions), inputs.product) && needs.changes.outputs.product_changes == 'true' }} + shell: bash + working-directory: contracts + run: | + ./scripts/lcov_prune ${{ inputs.product }} ./code-coverage/lcov.info ./code-coverage/lcov.info.pruned + - name: Generate Code Coverage HTML report for product contracts if: ${{ !contains(fromJson(steps.prepare-exclusion-list.outputs.coverage_exclusions), inputs.product) && needs.changes.outputs.product_changes == 'true' }} shell: bash working-directory: contracts - run: genhtml code-coverage/lcov.info --branch-coverage --output-directory code-coverage + run: genhtml code-coverage/lcov.info.pruned --branch-coverage --output-directory code-coverage - name: Run Forge doc for product contracts if: ${{ needs.changes.outputs.product_changes == 'true' }}