Skip to content

Commit

Permalink
Fixed coveralls (include all modules). *11
Browse files Browse the repository at this point in the history
  • Loading branch information
d4rken committed Mar 18, 2018
1 parent 9d16fe5 commit 8c5736f
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 23 deletions.
15 changes: 4 additions & 11 deletions build.gradle
Expand Up @@ -87,25 +87,19 @@ allprojects {

subprojects { subProject ->
def exclude = ['eu/darken/R*.class', '**/BuildConfig.class', '**/R.class', '**/R$*.class', '**/BuildConfig.*', '**/Manifest*.*']
apply plugin: 'jacoco'
task jacocoTestReport(type: JacocoReport, dependsOn: ['testDebugUnitTest']) {
reports {
xml.enabled = true
html.enabled = true
}

def debugTree = fileTree(dir: "$project.buildDir/intermediates/classes/debug", excludes: exclude)
def mainSrc = "${project.projectDir}/src/main/java"

sourceDirectories = files([mainSrc])
classDirectories = files([debugTree])
sourceDirectories = files(["${project.projectDir}/src/main/java"])
classDirectories = files([fileTree(dir: "$project.buildDir/intermediates/classes/debug", excludes: exclude)])
executionData = fileTree(dir: "$project.buildDir", includes: [
"jacoco/testDebugUnitTest.exec",
"outputs/code-coverage/connected/*coverage.ec"
"jacoco/testDebugUnitTest.exec"
])

rootProject.coveralls.sourceDirs.addAll(sourceDirectories.flatten())
println "println2" + rootProject.coveralls.sourceDirs
}

afterEvaluate {
Expand Down Expand Up @@ -142,10 +136,9 @@ task jacocoRootReport(type: JacocoReport, group: 'Coverage reports') {
html.enabled = true
xml.enabled = true
}

}

coveralls {
println "coveralls-sourcedir-final" + sourceDirs
jacocoReportPath = "${buildDir}/reports/jacoco/jacocoRootReport/jacocoRootReport.xml"
}

Expand Down
5 changes: 0 additions & 5 deletions core/build.gradle
Expand Up @@ -21,11 +21,6 @@ android {
textOutput 'stdout'
disable 'TimberTagLength'
}
buildTypes {
release {}
debug {
}
}
}
afterEvaluate {
javadoc.classpath += files(android.libraryVariants.collect { variant ->
Expand Down
2 changes: 0 additions & 2 deletions example/build.gradle
Expand Up @@ -22,8 +22,6 @@ android {
}

buildTypes {
debug {
}
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
Expand Down
5 changes: 0 additions & 5 deletions root/build.gradle
Expand Up @@ -21,11 +21,6 @@ android {
textOutput 'stdout'
disable 'TimberTagLength'
}
buildTypes {
release {}
debug {
}
}
}

dependencies {
Expand Down

0 comments on commit 8c5736f

Please sign in to comment.