Skip to content

jacoco-summary

Actions
Add coverage from JaCoCo report to workflow job summary
v1.1.1
Latest
Star (0)

Tags

 (1)

jacoco-summary

GitHub Action to add coverage from a JaCoCo report to the workflow job summary.

Usage

Add the following step to your GitHub Actions workflow after your tests and JaCoCo report generation:

- name: Add JaCoCo Coverage Summary
  uses: jjmrocha/jacoco-summary@v1
  with:
    jacoco-csv-file: path/to/jacoco.csv
  • jacoco-csv-file: Path to your JaCoCo CSV report file (defaults to build/reports/jacoco/test/jacocoTestReport.csv).

Example Workflow

name: CI

on:
  pull_request:
    branches: [main]

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - name: Set up JDK
        uses: actions/setup-java@v4
        with:
          java-version: '17'
          distribution: 'temurin'

      - name: Build and test with JaCoCo
        run: ./gradlew test jacocoTestReport

      - name: Add JaCoCo Coverage Summary
        uses: jjmrocha/jacoco-summary@v1

Output

The action parses the JaCoCo CSV report and adds a Markdown summary to the GitHub Actions job summary, showing overall and per-class coverage.

License

MIT

jacoco-summary is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

Add coverage from JaCoCo report to workflow job summary
v1.1.1
Latest

Tags

 (1)

jacoco-summary is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.