comparison metrics.gradle @ 119:740e905fce78

execute cobertura for bamboo builds
author smith@nwoca.org
date Sat, 03 Nov 2012 16:21:25 +0100
parents f84f1d5465c1
children b2532280341e
comparison
equal deleted inserted replaced
118:f84f1d5465c1 119:740e905fce78
75 } 75 }
76 if (gradle.bambooBuild) { 76 if (gradle.bambooBuild) {
77 coverageFormat = 'xml' 77 coverageFormat = 'xml'
78 } 78 }
79 } 79 }
80 80
81 if (gradle.bambooBuild) {
82 build.dependsOn 'cobertura'
83 }
84
81 } 85 }
82 86
83 root.allprojects { 87 root.allprojects {
84 88
85 def thisProject = delegate 89 def thisProject = delegate
86 def usesGroovy = thisProject.configurations.any { it.name == 'groovy' } 90 def usesGroovy = thisProject.configurations.any { it.name == 'groovy' }
87 91
88 sonar { 92 sonar {
94 props['sonar.core.codeCoveragePlugin'] = 'cobertura' 98 props['sonar.core.codeCoveragePlugin'] = 'cobertura'
95 props['sonar.language'] = usesGroovy ? 'grvy' : 'java' 99 props['sonar.language'] = usesGroovy ? 'grvy' : 'java'
96 } 100 }
97 } 101 }
98 } 102 }
99 103
100 } 104 }
101 } 105 }
102 } 106 }