Created
February 16, 2018 12:19
-
-
Save rafaeltoledo/8866850d6af6e039a63a5f21b7ecd0bd to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
task jacocoTestReport(type: JacocoReport, dependsOn: ['testDebugUnitTest', 'createDebugCoverageReport']) { | |
reports { | |
xml.enabled = true | |
html.enabled = true | |
} | |
def fileFilter = [ '**/R.class', '**/R$*.class', '**/BuildConfig.*', '**/Manifest*.*', '**/*Test*.*', 'android/**/*.*' ] | |
def debugTree = fileTree(dir: "$project.buildDir/tmp/kotlin-classes/debug", excludes: fileFilter) | |
def mainSrc = "$project.projectDir/src/main/kotlin" | |
sourceDirectories = files([mainSrc]) | |
classDirectories = files([debugTree]) | |
executionData = fileTree(dir: project.buildDir, includes: [ | |
'jacoco/testDebugUnitTest.exec', 'outputs/code-coverage/connected/*coverage.ec' | |
]) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment