We have a multi-module multi-language maven java project with coverage analysis with jacoco. The main part of the modules is backend (Java code) with a REST API and our webapp m
Im using a similar setup and everything works perfectly with the following configuration:
However the maven-surefire-plugin
was causing troubles initially. Thats why I had to add the @{argLine}
in the argLine tag, since the jacoco-maven-plugin:prepare-agent
goal is executed before the maven-surefire-plugin
.
(see https://stackoverflow.com/a/25774988)
Hope I could help
org.sonarsource.scanner.maven
sonar-maven-plugin
3.4.0.905
org.apache.maven.plugins
maven-surefire-plugin
test
@{argLine} -Xmx256m
org.jacoco
jacoco-maven-plugin
0.7.9
jacoco-initialize
prepare-agent
jacoco-site
package
report