From 3bd92711ac656103203476388be68eedcfdc6052 Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Thu, 3 Dec 2020 23:35:48 +0100 Subject: [PATCH] Exclude examples/smpi/mc from coverage analysis. --- sonar-project.properties | 4 +++- tools/jenkins/Coverage.sh | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/sonar-project.properties b/sonar-project.properties index 6904e019c1..2f51f36407 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -194,11 +194,13 @@ sonar.cfamily.threads=4 sonar.cfamily.gcov.reportsPath=Testing/CoverageInfo # Files to ignore from coverage analysis: # - foreign test suites +# - examples in smpi/mc (coverage doesn't work with model checker) # - XML files # - Python files used to generate either simcalls or deployment files # - Any java source code (it's deprecated now) # - MSG (deprecated too) -sonar.coverage.exclusions=teshsuite/smpi/isp/**,teshsuite/smpi/mpich3-test/**,**/*.xml,src/simix/simcalls.py,**/generate.py,**/*.java,src/bindings/java/**,src/msg/**,include/msg/**,examples/deprecated/**,teshsuite/msg/** +sonar.coverage.exclusions=teshsuite/smpi/isp/**,teshsuite/smpi/mpich3-test/**,examples/smpi/mc/**,**/*.xml,src/simix/simcalls.py,**/generate.py,**/*.java,src/bindings/java/**,src/msg/**,include/msg/**,examples/deprecated/**,teshsuite/msg/** + # Encoding of the source files sonar.sourceEncoding=UTF-8 diff --git a/tools/jenkins/Coverage.sh b/tools/jenkins/Coverage.sh index 823a94665a..aeab2768ff 100755 --- a/tools/jenkins/Coverage.sh +++ b/tools/jenkins/Coverage.sh @@ -97,7 +97,7 @@ if [ -f Testing/TAG ] ; then cd "$WORKSPACE" #convert all gcov reports to xml cobertura reports - gcovr -r . --xml-pretty -e teshsuite -u -o "$BUILDFOLDER"/xml_coverage.xml + gcovr -r . --xml-pretty -e teshsuite -e examples/smpi/NAS -e examples/smpi/mc -u -o "$BUILDFOLDER"/xml_coverage.xml xsltproc "$WORKSPACE"/tools/jenkins/ctest2junit.xsl build/Testing/"$( head -n 1 < build/Testing/TAG )"/Test.xml > CTestResults_memcheck.xml #generate sloccount report -- 2.20.1