[
https://issues.apache.org/jira/browse/HDDS-10101?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Attila Doroszlai updated HDDS-10101:
------------------------------------
Status: Patch Available (was: In Progress)
> Set sonar.coverage.jacoco.xmlReportPaths
> ----------------------------------------
>
> Key: HDDS-10101
> URL: https://issues.apache.org/jira/browse/HDDS-10101
> Project: Apache Ozone
> Issue Type: Improvement
> Components: CI
> Reporter: Attila Doroszlai
> Assignee: Attila Doroszlai
> Priority: Trivial
> Labels: pull-request-available
>
> {{sonar.sh}} copies the combined coverage report to all submodules:
> {code:title=https://github.com/apache/ozone/blob/2ae531b0f6a069db5a46bd486bb50225a168485d/hadoop-ozone/dev-support/checks/sonar.sh#L26-L31}
> #Workaround: Sonar expects per-project Sonar XML report, but we have one,
> combined. Sonar seems to handle it well.
> # Only the classes from the current project will be used. We can copy the
> same, combined report to all the subprojects.
> if [ -f "$PROJECT_DIR/target/coverage/all.xml" ]; then
> find "$PROJECT_DIR" -name pom.xml | grep -v target | xargs dirname | xargs
> -n1 -IDIR mkdir -p DIR/target/coverage/
> find "$PROJECT_DIR" -name pom.xml | grep -v target | xargs dirname | xargs
> -n1 -IDIR cp "$PROJECT_DIR/target/coverage/all.xml" DIR/target/coverage/
> fi
> {code}
> We can avoid the need for this hack by setting
> {{sonar.coverage.jacoco.xmlReportPaths}}.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]