From a6fc9fee0f9ad0b06a9937a40cd0823d28923972 Mon Sep 17 00:00:00 2001 From: AdrianLxM Date: Fri, 9 Jul 2021 20:02:22 +0200 Subject: [PATCH] update jacoco and add global config --- app/build.gradle | 10 +--------- automation/build.gradle | 1 + combo/build.gradle | 2 +- core/build.gradle | 2 +- dana/build.gradle | 2 +- danar/build.gradle | 2 +- danars/build.gradle | 1 + diaconn/build.gradle | 1 + gradle/jacoco_global.gradle | 8 ++++++++ insight/build.gradle | 2 +- medtronic/build.gradle | 2 +- omnipod-common/build.gradle | 2 +- omnipod-dash/build.gradle | 2 +- omnipod-eros/build.gradle | 2 +- pump-common/build.gradle | 2 +- rileylink/build.gradle | 2 +- wear/build.gradle | 7 ++++++- 17 files changed, 29 insertions(+), 21 deletions(-) create mode 100644 gradle/jacoco_global.gradle diff --git a/app/build.gradle b/app/build.gradle index cdd71b51ac..5118670c6c 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -6,15 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply plugin: 'com.google.firebase.crashlytics' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" - -jacoco { - toolVersion = "0.8.6" -} - -tasks.withType(Test) { - jacoco.includeNoLocationClasses = true - jacoco.excludes = ['jdk.internal.*'] -} +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" repositories { mavenCentral() diff --git a/automation/build.gradle b/automation/build.gradle index 54199af9b9..e3b5a31fa9 100644 --- a/automation/build.gradle +++ b/automation/build.gradle @@ -6,6 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { diff --git a/combo/build.gradle b/combo/build.gradle index e7f0567cf9..6e8a0ec0c6 100644 --- a/combo/build.gradle +++ b/combo/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/core/build.gradle b/core/build.gradle index e3a916bdae..7a71e453c1 100644 --- a/core/build.gradle +++ b/core/build.gradle @@ -8,7 +8,7 @@ apply from: 'core_dependencies.gradle' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':database') diff --git a/dana/build.gradle b/dana/build.gradle index 91897b762a..46e26b9616 100644 --- a/dana/build.gradle +++ b/dana/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" android { defaultConfig { diff --git a/danar/build.gradle b/danar/build.gradle index 0915729e0f..230038a50c 100644 --- a/danar/build.gradle +++ b/danar/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/danars/build.gradle b/danars/build.gradle index 075ebd5e0a..a013ae98af 100644 --- a/danars/build.gradle +++ b/danars/build.gradle @@ -6,6 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" android { ndkVersion "21.1.6352462" diff --git a/diaconn/build.gradle b/diaconn/build.gradle index 6194f079e3..2b1454339c 100644 --- a/diaconn/build.gradle +++ b/diaconn/build.gradle @@ -6,6 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" android { defaultConfig { diff --git a/gradle/jacoco_global.gradle b/gradle/jacoco_global.gradle new file mode 100644 index 0000000000..991d9597b6 --- /dev/null +++ b/gradle/jacoco_global.gradle @@ -0,0 +1,8 @@ +jacoco { + toolVersion = "0.8.7" +} + +tasks.withType(Test) { + jacoco.includeNoLocationClasses = true + jacoco.excludes = ['jdk.internal.*'] +} \ No newline at end of file diff --git a/insight/build.gradle b/insight/build.gradle index 91897b762a..46e26b9616 100644 --- a/insight/build.gradle +++ b/insight/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" android { defaultConfig { diff --git a/medtronic/build.gradle b/medtronic/build.gradle index 464f0c4d34..f7106a59bd 100644 --- a/medtronic/build.gradle +++ b/medtronic/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/omnipod-common/build.gradle b/omnipod-common/build.gradle index 4b8380b21a..aba1f22144 100644 --- a/omnipod-common/build.gradle +++ b/omnipod-common/build.gradle @@ -7,7 +7,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/omnipod-dash/build.gradle b/omnipod-dash/build.gradle index 07c4af856d..fa2e0aa670 100644 --- a/omnipod-dash/build.gradle +++ b/omnipod-dash/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/omnipod-eros/build.gradle b/omnipod-eros/build.gradle index 83c088300f..db27c83b0e 100644 --- a/omnipod-eros/build.gradle +++ b/omnipod-eros/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/pump-common/build.gradle b/pump-common/build.gradle index 9923421f06..5bb1a09fa4 100644 --- a/pump-common/build.gradle +++ b/pump-common/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/rileylink/build.gradle b/rileylink/build.gradle index 1ae5804c92..edbb3c241d 100644 --- a/rileylink/build.gradle +++ b/rileylink/build.gradle @@ -6,7 +6,7 @@ apply plugin: 'com.hiya.jacoco-android' apply from: "${project.rootDir}/gradle/android_dependencies.gradle" apply from: "${project.rootDir}/gradle/android_module_dependencies.gradle" apply from: "${project.rootDir}/gradle/test_dependencies.gradle" - +apply from: "${project.rootDir}/gradle/jacoco_global.gradle" dependencies { implementation project(':core') diff --git a/wear/build.gradle b/wear/build.gradle index 237d585dfc..c72db5dfa5 100644 --- a/wear/build.gradle +++ b/wear/build.gradle @@ -15,7 +15,12 @@ apply plugin: 'kotlin-android' apply plugin: 'com.hiya.jacoco-android' jacoco { - toolVersion = "0.8.6" + toolVersion = "0.8.7" +} + +tasks.withType(Test) { + jacoco.includeNoLocationClasses = true + jacoco.excludes = ['jdk.internal.*'] } ext {