Skip to content

Commit

Permalink
add JaCoCo test coverage and report
Browse files Browse the repository at this point in the history
  • Loading branch information
acaiado committed Mar 6, 2024
1 parent b50eab7 commit 17920ca
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/CI-CD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,30 @@ jobs:
run: |
echo "Running the tests"
./mvnw test
- name: JaCoCo Code Coverage Report
id: jacoco_reporter
uses: PavanMudigonda/[email protected]
with:
coverage_results_path: jacoco-report/test.xml
coverage_report_name: Coverage
coverage_report_title: JaCoCo
github_token: ${{ secrets.GITHUB_TOKEN }}
skip_check_run: false
minimum_coverage: 80
fail_below_threshold: false
publish_only_summary: false

# Publish Coverage Job Summary # Optional
- name: Add Coverage Job Summary
run: echo "${{ steps.jacoco_reporter.outputs.coverageSummary }}" >> $GITHUB_STEP_SUMMARY

# uploads the coverage-report.md artifact # Optional
- name: Upload Code Coverage Artifacts
uses: actions/upload-artifact@v2
with:
name: code-coverage-report-markdown
path: */coverage-results.md
retention-days: 1
build-image-push:
runs-on: ubuntu-latest
needs: [prepare, build-and-test]
Expand Down

0 comments on commit 17920ca

Please sign in to comment.