-
Notifications
You must be signed in to change notification settings - Fork 4
/
build.gradle
107 lines (86 loc) · 2.41 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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'me.tatarka:gradle-retrolambda:2.5.0'
classpath 'com.novoda:bintray-release:0.3.4'
classpath 'org.kt3k.gradle.plugin:coveralls-gradle-plugin:2.6.3'
}
}
apply plugin: 'java'
apply plugin: 'me.tatarka.retrolambda'
targetCompatibility = '1.8'
sourceCompatibility = '1.8'
retrolambda {
// ```bash
// export JAVA8_HOME="/usr/lib/jvm/java-8-oracle"
// export JAVA7_HOME="/usr/lib/jvm/java-7-oracle"
// export JAVA_HOME="$JAVA8_HOME"
// ```
//jvmArgs '-noverify'
jdk System.getenv("JAVA8_HOME")
//oldJdk System.getenv("JAVA_HOME")
oldJdk System.getenv("JAVA7_HOME")
javaVersion JavaVersion.VERSION_1_7
}
repositories {
jcenter()
maven { url "https://jitpack.io" }
}
dependencies {
compile 'io.reactivex.rxjava2:rxjava:2.0.8'
compile 'com.parse.bolts:bolts-tasks:1.4.0'
testCompile 'junit:junit:4.12'
testCompile 'org.mockito:mockito-core:1.10.19'
testCompile 'com.squareup.okhttp:mockwebserver:2.4.0'
testCompile 'com.github.yongjhih:mocker:0.1.2'
testCompile 'org.assertj:assertj-core:2.6.0'
}
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:deprecation" << "-Xlint:unchecked"
}
apply plugin: 'com.novoda.bintray-release'
def getRepositoryUsername() {
return hasProperty('BINTRAY_USER') ? BINTRAY_USER : ""
}
def getRepositoryPassword() {
return hasProperty('BINTRAY_KEY') ? BINTRAY_KEY : ""
}
publish {
userOrg = 'yongjhih'
groupId = 'com.infstory'
artifactId = 'rxbolts2-tasks'
publishVersion = '2.0.0'
desc = 'Reactive Bolts.'
website = 'https://github.com/yongjhih/RxBolts'
bintrayUser = getRepositoryUsername()
bintrayKey = getRepositoryPassword()
dryRun = false
}
apply plugin: 'maven'
apply from: 'javadoc.gradle'
apply plugin: 'jacoco'
jacocoTestReport {
reports {
xml.enabled = true // coveralls plugin depends on xml format report
html.enabled = true
}
}
apply plugin: 'com.github.kt3k.coveralls'
coveralls {
jacocoReportPath "$buildDir/reports/jacoco/test/jacocoTestReport.xml"
}
tasks.coveralls {
dependsOn 'jacocoTestReport'
}
tasks.jacocoTestReport {
dependsOn 'test'
}
tasks.withType(Test) {
testLogging {
exceptionFormat "full"
events "passed", "skipped", "failed", "standardOut", "standardError"
showStandardStreams = true
}
}