1// Copyright (C) 2020 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//      http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14apply from: "$gradle.ext.exoplayerSettingsDir/common_library_config.gradle"
15
16android {
17    buildTypes {
18        debug {
19            testCoverageEnabled = true
20        }
21    }
22}
23
24dependencies {
25    api ('com.google.guava:guava:' + guavaVersion) {
26        // Exclude dependencies that are only used by Guava at compile time
27        // (but declared as runtime deps) [internal b/168188131].
28        exclude group: 'com.google.code.findbugs', module: 'jsr305'
29        exclude group: 'org.checkerframework', module: 'checker-compat-qual'
30        exclude group: 'org.checkerframework', module: 'checker-qual'
31        exclude group: 'com.google.errorprone', module: 'error_prone_annotations'
32        exclude group: 'com.google.j2objc', module: 'j2objc-annotations'
33        exclude group: 'org.codehaus.mojo', module: 'animal-sniffer-annotations'
34    }
35    implementation 'androidx.annotation:annotation:' + androidxAnnotationVersion
36    compileOnly 'com.google.code.findbugs:jsr305:' + jsr305Version
37    compileOnly 'com.google.errorprone:error_prone_annotations:' + errorProneVersion
38    compileOnly 'org.checkerframework:checker-compat-qual:' + checkerframeworkCompatVersion
39    compileOnly 'org.checkerframework:checker-qual:' + checkerframeworkVersion
40    compileOnly 'org.jetbrains.kotlin:kotlin-annotations-jvm:' + kotlinAnnotationsVersion
41    androidTestImplementation 'androidx.test:runner:' + androidxTestRunnerVersion
42    androidTestImplementation 'com.linkedin.dexmaker:dexmaker:' + dexmakerVersion
43    androidTestImplementation 'com.linkedin.dexmaker:dexmaker-mockito:' + dexmakerVersion
44    androidTestImplementation(project(modulePrefix + 'testutils')) {
45        exclude module: modulePrefix.substring(1) + 'library-core'
46    }
47    testImplementation 'org.mockito:mockito-core:' + mockitoVersion
48    testImplementation 'androidx.test:core:' + androidxTestCoreVersion
49    testImplementation 'androidx.test.ext:junit:' + androidxTestJUnitVersion
50    testImplementation 'junit:junit:' + junitVersion
51    testImplementation 'com.google.truth:truth:' + truthVersion
52    testImplementation 'org.robolectric:robolectric:' + robolectricVersion
53    testImplementation project(modulePrefix + 'testutils')
54}
55
56ext {
57    javadocTitle = 'Common module'
58}
59apply from: '../../javadoc_library.gradle'
60
61ext {
62    releaseArtifactId = 'exoplayer-common'
63    releaseDescription = 'The ExoPlayer library common module.'
64}
65apply from: '../../publish.gradle'
66