File tree 3 files changed +50
-4
lines changed
3 files changed +50
-4
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,9 @@ buildscript {
13
13
classpath " gradle.plugin.com.github.erdi.webdriver-binaries:webdriver-binaries-gradle-plugin:$webdriverBinariesVersion "
14
14
}
15
15
}
16
+ plugins {
17
+ id ' jacoco'
18
+ }
16
19
17
20
18
21
version " 5.3-SNAPSHOT"
@@ -28,6 +31,9 @@ apply plugin:"com.github.erdi.webdriver-binaries"
28
31
if (Boolean . valueOf(enableClover)) {
29
32
apply from : " ${ project.projectDir} /gradle/clover.gradle"
30
33
}
34
+ if (Boolean . valueOf(enableJacoco)) {
35
+ apply from : " ${ project.projectDir} /gradle/jacoco.gradle"
36
+ }
31
37
32
38
33
39
repositories {
Original file line number Diff line number Diff line change 1
- groovyVersion =3.0.7
2
- grailsVersion =5.1 .2
1
+ groovyVersion =3.0.11
2
+ grailsVersion =5.3 .2
3
3
gorm.version =7.1.2
4
- grailsGradlePluginVersion =5.1.1
4
+ grailsGradlePluginVersion =5.3.0
5
5
org.gradle.daemon =true
6
6
org.gradle.parallel =true
7
7
# grailsWrapperVersion=1.0.0
8
8
# gradleWrapperVersion=5.0
9
- assetPipelineVersion =3.3.4
9
+ assetPipelineVersion =3.4.7
10
10
seleniumVersion =4.0.0
11
11
webdriverBinariesVersion =2.6
12
12
seleniumSafariDriverVersion =4.0.0
13
13
org.gradle.jvmargs =-Dfile.encoding=UTF-8 -Xss2048k -Xmx1024M
14
14
exploded =true
15
15
enableClover =false
16
+ enableJacoco =true
Original file line number Diff line number Diff line change
1
+ apply plugin :" jacoco"
2
+ jacoco {
3
+ toolVersion = " 0.8.8"
4
+ }
5
+
6
+ test {
7
+ useJUnitPlatform()
8
+ jacoco {
9
+ excludes = [' **/Application.groovy' ,
10
+ ' **/BootStrap.groovy' ,
11
+ ' **/UrlMappings.groovy' ,
12
+ ' **/*GrailsPlugin.groovy' ,
13
+ ' **/*Mock.groovy' ,
14
+ ' com.skedgo.converter.*' ]
15
+ }
16
+ finalizedBy jacocoTestReport // report is always generated after tests run
17
+ }
18
+
19
+ jacocoTestReport {
20
+ dependsOn test
21
+ finalizedBy jacocoTestCoverageVerification // report is always generated after tests run
22
+
23
+ reports {
24
+ xml. enabled false
25
+ csv. enabled false
26
+ html. destination file(" ${ buildDir} /reports/jacocoHtml" )
27
+ }
28
+ }
29
+
30
+ jacocoTestCoverageVerification {
31
+ dependsOn test
32
+ violationRules {
33
+ rule {
34
+ limit {
35
+ minimum = 0.2
36
+ }
37
+ }
38
+ }
39
+ }
You can’t perform that action at this time.
0 commit comments