Skip to content

#984 Set up builds and tests to run per changed module #2

#984 Set up builds and tests to run per changed module

#984 Set up builds and tests to run per changed module #2

Workflow file for this run

name: Test coverage
on:
pull_request:
paths:
- 'hartshorn-*/**'
jobs:
coverage:
name: Code coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up source JDK
uses: actions/setup-java@v3
with:
java-version: 17
distribution: temurin
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- name: Run tests
run: ./gradlew jacocoMergedReport
- name: Add coverage to PR
id: jacoco
uses: madrapps/[email protected]
with:
title: Code coverage
update-comment: true
paths: |
${{ github.workspace }}/build/reports/jacoco/jacocoMergedReport/jacocoMergedReport.xml
token: ${{ secrets.GITHUB_TOKEN }}
min-coverage-overall: 80
min-coverage-changed-files: 80
- name: Verify coverage report
run: ./gradlew jacocoTestCoverageVerification