I want to display the coverage of java project on SonarQube.
I am using sonar-scanner.
However, the coverage is not reflected on SonarQube.
Please let me know if there is something missing in the execution content.
【Execution content】
①Run the following in a JDK 11 environment
mvn test jacoco:report
(Create “./target/site/jacoco/jacoco.xml”)
Next, in the JDK8 environment, the following was executed for the execution result of ①.
./node_modules/.bin/sonar-scanner
-Dsonar.host.url=http://xx.xx.xx.xx:9000/sonarqube
-Dsonar.projectBaseDir=./
-Dsonar.sources=./src
-Dsonar.exclusions=src/main/resources/**
-Dsonar.test=src/test
-Dsonar.sourceEncoding=UTF-8
-Dsonar.projectKey=xxxxxxxxx
-Dsonar.projectName=xxxxxxxxx
-Dsonar.dynamicAnalysis=false
-Dsonar.java.binaries=target/classes
-Dsonar.coverage.jacoco.xmlReportPaths=./target/site/jacoco/jacoco.xml
【version information】
SonarQube Community EditionVersion 7.3 (build 15553)
sonar-java-plugin-5.6.1.15064.jar
SonarQube Scanner 3.1.0.1141
Java 1.8.0_201 Oracle Corporation (64-bit)
Linux 5.10.16.3-microsoft-standard-WSL2 amd64