diff --git a/Jenkinsfile b/Jenkinsfile index 38e58823..4418c636 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -88,35 +88,33 @@ pipeline { //# } -//#stage('Report to SonarQube') { -//# steps { -//# node(label: 'docker') { -//# script{ -//# // get the code -//# checkout scm -//# // get the result of the tests that were run in a previous Jenkins test -//# dir("xunit-reports") { -//# unstash "xunit-reports" -//# } -//# // get the result of the cobertura test -//# unstash "coverage.xml" -//# // get the sonar-scanner binary location -//# def scannerHome = tool 'SonarQubeScanner'; -//# // get the nodejs binary location -//# def nodeJS = tool 'NodeJS11'; -//# // run with the SonarQube configuration of API and token -//# withSonarQubeEnv('Sonarqube') { -//# // make sure you have the same path to the code as in the coverage report -//# sh '''sed -i "s|/plone/instance/src/$GIT_NAME|$(pwd)|g" coverage.xml''' -//# // run sonar scanner -//# sh "export PATH=$PATH:${scannerHome}/bin:${nodeJS}/bin; sonar-scanner -Dsonar.python.xunit.skipDetails=true -Dsonar.python.xunit.reportPath=xunit-reports/*.xml -Dsonar.python.coverage.reportPath=coverage.xml -Dsonar.sources=./eea -Dsonar.projectKey=$GIT_NAME-$BRANCH_NAME -Dsonar.projectVersion=$BRANCH_NAME-$BUILD_NUMBER" -//# } -//# } -//# } -//# } -//#} - - +//stage('Report to SonarQube') { +// steps { +// node(label: 'docker') { +// script{ +// // get the code +// checkout scm +// // get the result of the tests that were run in a previous Jenkins test +// dir("xunit-reports") { +// unstash "xunit-reports" +// } +// // get the result of the cobertura test +// unstash "coverage.xml" +// // get the sonar-scanner binary location +// def scannerHome = tool 'SonarQubeScanner'; +// // get the nodejs binary location +// def nodeJS = tool 'NodeJS11'; +// // run with the SonarQube configuration of API and token +// withSonarQubeEnv('Sonarqube') { +// // make sure you have the same path to the code as in the coverage report +// sh '''sed -i "s|/plone/instance/src/$GIT_NAME|$(pwd)|g" coverage.xml''' +// // run sonar scanner +// sh "export PATH=$PATH:${scannerHome}/bin:${nodeJS}/bin; sonar-scanner -Dsonar.python.xunit.skipDetails=true -Dsonar.python.xunit.reportPath=xunit-reports/*.xml -Dsonar.python.coverage.reportPath=coverage.xml -Dsonar.sources=./eea -Dsonar.projectKey=$GIT_NAME-$BRANCH_NAME -Dsonar.projectVersion=$BRANCH_NAME-$BUILD_NUMBER" +// } +// } +// } +// } +//} stage('Pull Request') { when {