Hoping I could get some help with finding out why my c++ coverage report information is not loading.
I am using a unit testing framework called Catch2. The Catch2 documentation tells me the following:
SonarQube Reporter
-r sonarqube
SonarQube Generic Test Data XML format for tests metrics.
link to the documentation:
It would appear the coverage report is getting generated.
The following is my sonar-project.properties
file:
sonar.organization=imanage
sonar.projectName=Work Server Core
sonar.projectKey=work-server-core
sonar.working.directory=target/sonar
sonar.cfamily.threads=3
sonar.cfamily.cache.enabled=true
sonar.cfamily.cache.path=sonar/sonar-cache/target/sonar-cache
#combine python and c++ analysis
sonar.sources=mlib,app
sonar.exclusions=**/tests,mlib/**/restclient-tests,mlib/**/restclient-mocks,mlib/**/DownloadTest,**/target,thirdparty
#sonar.exclusions=app/**/tests/**,mlib/**/restclient-tests/**,mlib/**/restclient-mocks/**,mlib/**/DownloadTest/**,mlib/**/target/**,app/**/target/**
sonar.cfamily.build-wrapper-output=build_wrapper_output_directory
sonar.cxx.coverage.reportPath=test/**/sonar-*.xml
sonar.python.coverage.reportPaths=app/pymodule/coverage.xml
My python coverage is being reported correctly. I have debug information turned on for the sonar processing. I do not see anything (including errors) regarding loading the coverage files for either python or cxx. But my python coverage is showing correctly on sonarcloud.
Not sure if I am just missing something simple or what I am trying to do simply is not supported for c++. I find some conflicting documentation. The sonar documentation seems to be very specific about what tools can be used to generate the c++ coverage files. Other documentation, like the catch2 documentation, indicates that sonar will support their coverage file.
Can someone help point me in the correct direction?
Thanks…