Home | History | Annotate | Download | only in espresso-lib-tests
      1 /*
      2  * Copyright (C) 2014 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  */
     16 
     17 apply plugin: 'android'
     18 
     19 repositories {
     20     maven { url '../../../../prebuilts/tools/common/m2/repository' }
     21     maven { url '../../../../prebuilts/tools/common/m2/internal' }
     22 }
     23 
     24 android {
     25     compileSdkVersion 19
     26     buildToolsVersion "19.0.3"
     27 
     28     packagingOptions {
     29         exclude 'LICENSE.txt'
     30     }
     31 
     32     lintOptions {
     33         abortOnError false
     34     }
     35 
     36     defaultConfig {
     37         testInstrumentationRunner "com.google.android.apps.common.testing.testrunner.GoogleInstrumentationTestRunner"
     38     }
     39 
     40     sourceSets {
     41         // Setting espresso-sample as the main root of this project to avoid source code duplication.
     42         // Temporary workaround until Android Gradle plugin supports settings custom target package
     43         // for Android Tests.
     44         main.setRoot("../espresso-sample/src/main")
     45     }
     46 }
     47 
     48 dependencies {
     49     compile files('../libs/guava-14.0.1.jar')
     50     compile 'com.android.support:support-v4:19.1.+'
     51     compile 'com.android.support:appcompat-v7:19.1.+'
     52 
     53     // run test against an un-jarjared variant of the lib
     54     androidTestCompile project(path: ':espresso-lib', configuration: 'debug')
     55 
     56     androidTestCompile 'org.mockito:mockito-core:1.9.5'
     57     androidTestCompile 'com.google.dexmaker:dexmaker-mockito:1.0'
     58 }
     59 
     60 apply from: "$rootDir/javadoc.gradle"
     61