From f0fe8f947cb0191664b963af6ca512358f049045 Mon Sep 17 00:00:00 2001 From: Matthew Gardner <8501252+matthewgardner@users.noreply.github.com> Date: Wed, 29 May 2024 11:24:36 +0100 Subject: [PATCH] Add jacoco test and action (#190) * Add jacoco test and action * set version for plugin * Add logging to help debug * Remove the path * add wildcard search * downgrade action * Restore fully qualified path to file * Revert accidental deletion * Add permission to write-all * Try pull-requests: write * Added check that publish can run on non-fork * update permission * disable for now --------- Co-authored-by: Matthew Bain <66839492+rocketstack-matt@users.noreply.github.com> --- .github/workflows/translator.yml | 11 ++++++++++- translator/pom.xml | 19 +++++++++++++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/.github/workflows/translator.yml b/.github/workflows/translator.yml index 18a0e0e4..d28e80a4 100644 --- a/.github/workflows/translator.yml +++ b/.github/workflows/translator.yml @@ -20,4 +20,13 @@ jobs: java-version: '21' distribution: 'temurin' cache: maven - - run: mvn -B install --file ./translator/pom.xml \ No newline at end of file + - run: mvn -B install --file ./translator/pom.xml + # - name: Add coverage to PR + # id: jacoco + # uses: madrapps/jacoco-report@v1.4 + # with: + # paths: ${{ github.workspace }}/translator/target/site/jacoco/jacoco.xml + # token: ${{ secrets.GITHUB_TOKEN }} + # min-coverage-overall: 80 + # min-coverage-changed-files: 80 + diff --git a/translator/pom.xml b/translator/pom.xml index 0d572814..f4466f62 100644 --- a/translator/pom.xml +++ b/translator/pom.xml @@ -93,6 +93,25 @@ + + org.jacoco + jacoco-maven-plugin + 0.8.12 + + + + prepare-agent + + + + report + test + + report + + + +