Skip to content

Commit

Permalink
[Misc] Try to configure sonarqube analysis so that tests in one modul…
Browse files Browse the repository at this point in the history
…e that indirectly exercise code in other modules are counted
  • Loading branch information
vmassol committed Nov 19, 2019
1 parent 73e6f88 commit 21f7e4f
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -78,11 +78,19 @@ stage ('Commons Builds') {
'quality': {
node {
// Run the quality checks.
// Sonar notes:
// - we need sonar:sonar to perform the analysis
// - we need sonar = true to push the analysis to Sonarcloud
// - we need jacoco:report to execute jacoco and compute test coverage
// - we need -Pcoverage and -Dxwiki.jacoco.itDestFile to tell Jacoco to compute a single global Jacoco
// coverage for the full reactor (so that the coverage percentage computed takes into account module tests
// which cover code in other modules)
xwikiBuild('Quality') {
xvnc = false
mavenOpts = globalMavenOpts
goals = 'clean install jacoco:report sonar:sonar'
profiles = 'quality,legacy'
profiles = 'quality,legacy,coverage'
properties = '-Dxwiki.jacoco.itDestFile=`pwd`/target/jacoco-it.exec'
sonar = true
javadoc = false
}
Expand Down

0 comments on commit 21f7e4f

Please sign in to comment.