forked from bcgit/bc-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
94 lines (80 loc) · 2.78 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
buildscript {
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath "net.saliman:gradle-cobertura-plugin:2.2.8"
}
}
if (JavaVersion.current().isJava8Compatible()) {
allprojects {
tasks.withType(Javadoc) {
options.addStringOption('Xdoclint:none', '-quiet')
}
}
}
allprojects {
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'net.saliman.cobertura'
repositories {
mavenCentral()
}
dependencies {
testCompile group: 'junit', name: 'junit', version: '4.11'
// Cobertura declares a dependency on the slf4j API, so we need to supply
// a runtime implementation to avoid NoClassDefFoundErrors
testRuntime "org.slf4j:slf4j-log4j12:1.7.5"
testRuntime "log4j:log4j:1.2.17"
}
}
ext {
bcTestDataHome = file('core/src/test/data').absolutePath
}
task printProperties << {
println bcTestDataHome
}
subprojects {
apply plugin: 'eclipse'
sourceCompatibility = 1.5
targetCompatibility = 1.5
version = '1.59'
test {
systemProperty 'bc.test.data.home', bcTestDataHome
filter {
includeTestsMatching "*AllTests"
}
}
}
test.dependsOn([':core:test', ':prov:test', ':tls:test', ':pkix:test', ':mail:test', 'pg:test'])
cobertura {
coverageDirs = [
"${rootProject.projectDir}/core/build/classes/main",
"${rootProject.projectDir}/mail/build/classes/main",
"${rootProject.projectDir}/pg/build/classes/main",
"${rootProject.projectDir}/pkix/build/classes/main",
"${rootProject.projectDir}/prov/build/classes/main",
"${rootProject.projectDir}/tls/build/classes/main",
]
coverageSourceDirs = [
"${rootProject.projectDir}/core/src/main/java",
"${rootProject.projectDir}/mail/src/main/java",
"${rootProject.projectDir}/pg/src/main/java",
"${rootProject.projectDir}/pkix/src/main/java",
"${rootProject.projectDir}/prov/src/main/java",
"${rootProject.projectDir}/tls/src/main/java",
]
coverageMergeDatafiles = [
file("${rootProject.projectDir}/core/build/cobertura/cobertura.ser"),
file("${rootProject.projectDir}/mail/build/cobertura/cobertura.ser"),
file("${rootProject.projectDir}/pg/build/cobertura/cobertura.ser"),
file("${rootProject.projectDir}/pkix/build/cobertura/cobertura.ser"),
file("${rootProject.projectDir}/prov/build/cobertura/cobertura.ser"),
file("${rootProject.projectDir}/tls/build/cobertura/cobertura.ser"),
]
auxiliaryClasspath += files("${rootProject.projectDir}/core/build/classes/main")
coverageFormats = ['html', 'xml']
coverageReportDir = new File("${rootProject.projectDir}/build/reports/cobertura")
}