From e329a4d1c9db59150fcbee6eea2177ccd934c353 Mon Sep 17 00:00:00 2001 From: Tamas Cservenak Date: Mon, 3 Jun 2024 19:10:44 +0200 Subject: [PATCH 1/3] Fix jacoco + code coverage --- .github/workflows/build.yml | 2 +- org.eclipse.sisu.inject/pom.xml | 15 +++++++++++---- org.eclipse.sisu.plexus/pom.xml | 18 ++++++++++++++---- pom.xml | 11 ----------- 4 files changed, 26 insertions(+), 20 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a24c4396..629050b4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -30,7 +30,7 @@ jobs: run: | if [ "${{ matrix.isMainBuildEnv }}" = "true" ]; then echo "SONAR_TOKEN=${{ secrets.SONAR_TOKEN }}" >> $GITHUB_ENV - echo "MVN_ADDITIONAL_OPTS=org.sonarsource.scanner.maven:sonar-maven-plugin:4.0.0.4121:sonar -Dsonar.host.url=https://sonarcloud.io -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} -Dsonar.organization=${{ vars.SONAR_ORGANIZATION }}" >> $GITHUB_ENV + echo "MVN_ADDITIONAL_OPTS=org.sonarsource.scanner.maven:sonar-maven-plugin:4.0.0.4121:sonar -Dsonar.host.url=https://sonarcloud.io -Dsonar.projectKey=${{ vars.SONAR_PROJECT_KEY }} -Dsonar.organization=${{ vars.SONAR_ORGANIZATION }} -Pcode-coverage" >> $GITHUB_ENV echo "GIT_FETCH_DEPTH=0" >> $GITHUB_ENV # Shallow clones should be disabled for a better relevancy of analysis else echo "MVN_ADDITIONAL_OPTS=" >> $GITHUB_ENV diff --git a/org.eclipse.sisu.inject/pom.xml b/org.eclipse.sisu.inject/pom.xml index 95f74855..5f03a992 100644 --- a/org.eclipse.sisu.inject/pom.xml +++ b/org.eclipse.sisu.inject/pom.xml @@ -423,10 +423,6 @@ - - org.jacoco - jacoco-maven-plugin - @@ -478,5 +474,16 @@ + + code-coverage + + + + org.jacoco + jacoco-maven-plugin + + + + diff --git a/org.eclipse.sisu.plexus/pom.xml b/org.eclipse.sisu.plexus/pom.xml index 8ac97e91..c96beedd 100644 --- a/org.eclipse.sisu.plexus/pom.xml +++ b/org.eclipse.sisu.plexus/pom.xml @@ -439,11 +439,21 @@ - - org.jacoco - jacoco-maven-plugin - + + + code-coverage + + + + org.jacoco + jacoco-maven-plugin + + + + + + diff --git a/pom.xml b/pom.xml index e02548c9..0650db6b 100644 --- a/pom.xml +++ b/pom.xml @@ -674,16 +674,5 @@ Bundle-DocURL: http://www.eclipse.org/sisu/ - - code-coverage - - - - org.jacoco - jacoco-maven-plugin - - - - From 1702a880ba1f484ae49a45ec3fcbc2b130de8aec Mon Sep 17 00:00:00 2001 From: Tamas Cservenak Date: Mon, 3 Jun 2024 19:15:41 +0200 Subject: [PATCH 2/3] Fix missing property As it causes all kind of cli breakage when invoking tools and jvm. --- org.eclipse.sisu.plexus/pom.xml | 2 -- pom.xml | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/org.eclipse.sisu.plexus/pom.xml b/org.eclipse.sisu.plexus/pom.xml index c96beedd..f1d20569 100644 --- a/org.eclipse.sisu.plexus/pom.xml +++ b/org.eclipse.sisu.plexus/pom.xml @@ -441,7 +441,6 @@ - code-coverage @@ -455,5 +454,4 @@ - diff --git a/pom.xml b/pom.xml index 0650db6b..7e620600 100644 --- a/pom.xml +++ b/pom.xml @@ -116,6 +116,7 @@ https://raw.githubusercontent.com/eclipse-sisu/sisu-project/main/license-header-epl2.txt ${project.inceptionYear}-2024 + 3.2.5 From 497db43db9aabec134c6e3a0a5b504e2233d7041 Mon Sep 17 00:00:00 2001 From: Tamas Cservenak Date: Mon, 3 Jun 2024 19:23:21 +0200 Subject: [PATCH 3/3] Point to jacoco XMLs --- pom.xml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pom.xml b/pom.xml index 7e620600..2cd259fd 100644 --- a/pom.xml +++ b/pom.xml @@ -116,7 +116,13 @@ https://raw.githubusercontent.com/eclipse-sisu/sisu-project/main/license-header-epl2.txt ${project.inceptionYear}-2024 + + + + ${maven.multiModuleProjectDirectory}/org.eclipse.sisu.inject/target/site/jacoco/jacoco.xml, + ${maven.multiModuleProjectDirectory}/org.eclipse.sisu.plexus/target/site/jacoco/jacoco.xml + 3.2.5