Add support for SonarCloud analysis

This commit is contained in:
Jonathan White 2018-06-18 23:34:30 -04:00
parent 5df8ddfc3f
commit 9805f2331d
No known key found for this signature in database
GPG key ID: 440FC65F2E0C6E01
3 changed files with 24 additions and 1 deletions

View file

@ -131,6 +131,10 @@ FUNCTION(SETUP_TARGET_FOR_COVERAGE _targetname _testrunner _outputname)
ENDIF() # NOT GENHTML_PATH
SET(coverage_info "${CMAKE_BINARY_DIR}/${_outputname}.info")
IF(MINGW)
# Replace C:/ with /C for MINGW
STRING(REGEX REPLACE "^([a-zA-Z]):" "/\\1" coverage_info ${coverage_info})
ENDIF()
SET(coverage_cleaned "${coverage_info}.cleaned")
SEPARATE_ARGUMENTS(test_command UNIX_COMMAND "${_testrunner}")