Bug 1802817 - Set namespace via DSL in gradle build files.
[gecko.git] / mobile / android / android-components / components / feature / top-sites / build.gradle
blobe0320dadf5f950b8f1746b2006377a69f64ac99b
1 /* This Source Code Form is subject to the terms of the Mozilla Public
2  * License, v. 2.0. If a copy of the MPL was not distributed with this
3  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 apply plugin: 'com.android.library'
6 apply plugin: 'kotlin-android'
7 apply plugin: 'kotlin-kapt'
9 android {
10     compileSdkVersion config.compileSdkVersion
12     defaultConfig {
13         minSdkVersion config.minSdkVersion
14         targetSdkVersion config.targetSdkVersion
15         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
17         kapt {
18             arguments {
19                 arg("room.schemaLocation", "$projectDir/schemas".toString())
20             }
21         }
23         javaCompileOptions {
24             annotationProcessorOptions {
25                 arguments += ["room.incremental": "true"]
26             }
27         }
28     }
30     buildTypes {
31         release {
32             minifyEnabled false
33             proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
34         }
35     }
37     packagingOptions {
38         exclude 'META-INF/proguard/androidx-annotations.pro'
39     }
41     sourceSets {
42         androidTest.assets.srcDirs += files("$projectDir/schemas".toString())
43     }
45     namespace 'mozilla.components.feature.top.sites'
48 dependencies {
49     implementation project(':browser-storage-sync')
50     implementation project(':concept-toolbar')
51     implementation project(':support-ktx')
52     implementation project(':support-base')
53     implementation project(':support-utils')
55     implementation ComponentsDependencies.kotlin_stdlib
56     implementation ComponentsDependencies.kotlin_coroutines
58     implementation ComponentsDependencies.androidx_paging
59     implementation ComponentsDependencies.androidx_lifecycle_livedata
61     implementation ComponentsDependencies.androidx_room_runtime
62     kapt ComponentsDependencies.androidx_room_compiler
64     testImplementation project(':support-test')
66     testImplementation ComponentsDependencies.androidx_test_core
67     testImplementation ComponentsDependencies.androidx_test_junit
68     testImplementation ComponentsDependencies.testing_junit
69     testImplementation ComponentsDependencies.testing_mockito
70     testImplementation ComponentsDependencies.testing_coroutines
71     testImplementation ComponentsDependencies.testing_robolectric
72     testImplementation ComponentsDependencies.kotlin_coroutines
74     androidTestImplementation project(':support-android-test')
76     androidTestImplementation ComponentsDependencies.androidx_room_testing
77     androidTestImplementation ComponentsDependencies.androidx_arch_core_testing
78     androidTestImplementation ComponentsDependencies.androidx_test_core
79     androidTestImplementation ComponentsDependencies.androidx_test_runner
80     androidTestImplementation ComponentsDependencies.androidx_test_rules
81     androidTestImplementation ComponentsDependencies.testing_coroutines
84 apply from: '../../../android-lint.gradle'
85 apply from: '../../../publish.gradle'
86 ext.configurePublish(config.componentsGroupId, archivesBaseName, project.ext.description)