blob: b4a52cd7da3cd470b46d163cde3a6113b135c299 [file] [log] [blame]
Adam Powellb15ee752017-01-20 16:47:59 -08001/*
2 * Copyright (C) 2016 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
Sergey Vasilinetseb9d04ce2017-09-18 15:59:33 -070016
17import android.support.LibraryVersions
18import android.support.SupportLibraryExtension
19
Aurimas Liutikas3ba86932017-11-07 03:46:07 +000020plugins {
21 id("SupportAndroidLibraryPlugin")
22}
Adam Powellb15ee752017-01-20 16:47:59 -080023
24android {
Adam Powellb15ee752017-01-20 16:47:59 -080025 defaultConfig {
26 minSdkVersion flatfoot.min_sdk
Adam Powellb15ee752017-01-20 16:47:59 -080027 }
28
29 testOptions {
30 unitTests.returnDefaultValues = true
31 }
Adam Powellb15ee752017-01-20 16:47:59 -080032}
33
34dependencies {
35 compile libs.support.core_utils
36 compile libs.support.fragments
37
38 testCompile libs.junit
Ian Lake1ed814b52017-05-24 16:04:44 -070039 testCompile libs.mockito_core
40
Adam Powellb15ee752017-01-20 16:47:59 -080041 testCompile(libs.test_runner) {
42 exclude module: 'support-annotations'
43 }
Ian Lake1ed814b52017-05-24 16:04:44 -070044
45 androidTestCompile(libs.test_runner) {
46 exclude module: 'support-annotations'
47 }
Adam Powellb15ee752017-01-20 16:47:59 -080048 androidTestCompile(libs.espresso_core, {
49 exclude group: 'com.android.support', module: 'support-annotations'
50 })
51}
52
Ian Lake83cf00c2017-07-24 12:32:01 -070053createAndroidCheckstyle(project)
Adam Powellb15ee752017-01-20 16:47:59 -080054
55android.libraryVariants.all { variant ->
56 def name = variant.buildType.name
57 def suffix = name.capitalize()
58 def jarTask = project.tasks.create(name: "jar${suffix}", type: Jar){
59 dependsOn variant.javaCompile
60 from variant.javaCompile.destinationDir
61 destinationDir new File(project.buildDir, "libJar")
62 }
63}
Sergey Vasilinetseb9d04ce2017-09-18 15:59:33 -070064
65version = LibraryVersions.NAVIGATION.toString()
66supportLibrary {
67 name 'Android Navigation Runtime'
68 publish true
69 inceptionYear '2017'
70 description "Android Navigation-Runtime"
71 url SupportLibraryExtension.ARCHITECTURE_URL
72}