forked from oppia/oppia-android
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
111 lines (103 loc) · 3.51 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
108
109
110
111
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-kapt'
android {
compileSdkVersion 29
buildToolsVersion "29.0.2"
defaultConfig {
minSdkVersion 19
targetSdkVersion 29
versionCode 1
versionName "1.0"
javaCompileOptions {
annotationProcessorOptions {
includeCompileClasspath true
}
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = JavaVersion.VERSION_1_8
}
testOptions {
unitTests {
includeAndroidResources = true
all {
// Enable forking to ensure each test is properly run in isolation. For context, see:
// https://discuss.gradle.org/t/36066/2 & https://github.com/oppia/oppia-android/issues/1942
forkEvery = 1
maxParallelForks = Runtime.getRuntime().availableProcessors()
// https://discuss.gradle.org/t/29495/2 & https://stackoverflow.com/a/34299238.
testLogging {
events "passed", "skipped", "failed"
showExceptions = true
exceptionFormat = "full"
showCauses = true
showStackTraces = true
showStandardStreams = false
}
}
}
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation(
'androidx.appcompat:appcompat:1.0.2',
'androidx.lifecycle:lifecycle-livedata-ktx:2.2.0-alpha03',
'androidx.work:work-runtime-ktx:2.4.0',
'com.github.oppia:androidsvg:6bd15f69caee3e6857fcfcd123023716b4adec1d',
'com.github.bumptech.glide:glide:4.11.0',
'com.google.dagger:dagger:2.24',
'com.google.firebase:firebase-analytics-ktx:17.5.0',
'com.google.firebase:firebase-core:17.5.0',
'com.google.firebase:firebase-crashlytics:17.0.0',
'com.google.protobuf:protobuf-javalite:3.17.3',
"org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version",
)
compileOnly(
'jakarta.xml.bind:jakarta.xml.bind-api:2.3.2',
'javax.annotation:javax.annotation-api:1.3.2',
'org.glassfish.jaxb:jaxb-runtime:2.3.2',
)
testImplementation(
'androidx.test.ext:junit:1.1.1',
'androidx.test.ext:truth:1.4.0',
'com.google.dagger:dagger:2.24',
'com.google.truth:truth:1.1.3',
'com.google.truth.extensions:truth-liteproto-extension:1.1.3',
'junit:junit:4.12',
"org.jetbrains.kotlin:kotlin-test-junit:$kotlin_version",
'org.jetbrains.kotlinx:kotlinx-coroutines-test:1.2.2',
'org.mockito:mockito-core:2.19.0',
'org.robolectric:robolectric:4.4',
project(":testing"),
)
kapt(
'com.github.bumptech.glide:compiler:4.11.0',
'com.google.dagger:dagger-compiler:2.24'
)
kaptTest(
'com.google.dagger:dagger-compiler:2.24'
)
// TODO(#59): Remove this once Bazel is introduced
// sufficiently visible for generated Dagger code. This can be done more cleanly via Bazel since dependencies can be
// controlled more directly than in Gradle.
implementation project(':model')
}
// The GeneratedMessageLite implementations of protobufs are depending on protobuf-java
// instead of protobuf-lite after Android Studio 3.5,
// The below command stops that from happening: https://github.com/google/tink/issues/282
configurations {
all*.exclude module: 'protobuf-java'
}