1
0
mirror of https://github.com/wulkanowy/wulkanowy.git synced 2024-11-12 21:00:48 -06:00
wulkanowy-mirror/app/jacoco.gradle
Mikołaj Pich 7fe638130e
Configure github actions (#1055)
* Create test.yml

* Change list of emulator api levels

* Downgrade emulator with api 30 to 29

* Exclude jdk.internal in jacoco config

* Use jdk 15

* Downgrade jdk to 11 due to jacoco incompatibility

gradle/gradle#15038

* Fix tests on jdk11

* Add codecov

* Add missing jacoco report generaction command

* Add flags to codecov uploads

* Add deploy config

* Replace travis badge with gh actions badge

* Add info about coroutines to readme, replace dagger with hilt

* Decrease instrumentation tests to 15 minutes

* Skip duplicate actions

* Remove comment

* Change os of instrumentation tests

* Downgrade android emulator runner to v2.13.0

* Add pre-build job

* Pass prebuild files between jobs

* Fix gh actions yaml config

* Tar build cache

* Fix upload-artifact filename

* Fix prebuild cache name

* Add more to cache, change cache key
2020-12-27 17:30:50 +00:00

52 lines
1.3 KiB
Groovy

apply plugin: "jacoco"
jacoco {
toolVersion "0.8.5"
reportsDir = file("$buildDir/reports")
}
tasks.withType(Test) {
jacoco.includeNoLocationClasses = true
jacoco.excludes = ['jdk.internal.*']
}
task jacocoTestReport(type: JacocoReport) {
group = "Reporting"
description = "Generate Jacoco coverage reports"
reports {
xml.enabled = true
html.enabled = true
}
def excludes = ['**/R.class',
'**/R$*.class',
'**/BuildConfig.*',
'**/Manifest*.*',
'**/*Test*.*',
'android/**/*.*',
'**/*Module.*',
'**/*Dagger*.*',
'**/*MembersInjector*.*',
'**/*_Provide*Factory*.*',
'**/*_Factory.*']
classDirectories.setFrom(fileTree(
dir: "$buildDir/intermediates/classes/debug",
excludes: excludes
) + fileTree(
dir: "$buildDir/tmp/kotlin-classes/fdroidDebug",
excludes: excludes
))
sourceDirectories.setFrom(files([
"src/main/java",
"src/fdroid/java"
]))
executionData.setFrom(fileTree(
dir: project.projectDir,
includes: ["**/*.exec", "**/*.ec"]
))
}