apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-kapt'
apply plugin: "kotlin-allopen"

allOpen {
    annotation("it.codingjam.github.core.AllOpen")
}

android {
    compileSdkVersion 28

    defaultConfig {
        minSdkVersion 16
        targetSdkVersion 28
        versionCode 1
        versionName "1.0"
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    api project(':core')
    api project(':viewlib')

    implementation "com.jakewharton.timber:timber:$timber_version"

    implementation "com.google.dagger:dagger:$dagger_version"
    kapt "com.google.dagger:dagger-compiler:$dagger_version"

    api "androidx.legacy:legacy-support-v4:$support_version"
    api "com.google.android.material:material:$support_version"

    api "androidx.test:rules:1.1.1"
    api "androidx.test:core:1.1.0"
    api("androidx.test.espresso:espresso-core:$espresso_version", {
        exclude group: 'com.android.support', module: 'support-annotations'
        exclude group: 'com.google.code.findbugs', module: 'jsr305'
    })
    api("androidx.test.espresso:espresso-contrib:$espresso_version", {
        exclude group: 'com.android.support', module: 'support-annotations'
        exclude group: 'com.google.code.findbugs', module: 'jsr305'
    })

    api "androidx.arch.core:core-testing:2.0.1"
    api "org.mockito:mockito-android:$mockito_version"
    api('com.nhaarman.mockitokotlin2:mockito-kotlin:2.1.0') {
        exclude group: 'org.jetbrains.kotlin'
    }
    api 'com.github.fabioCollini.daggermock:daggermock:0.8.4'
    api('com.github.fabioCollini.daggermock:daggermock-kotlin:0.8.4') {
        exclude group: 'org.jetbrains.kotlin'
    }

    implementation "android.arch.navigation:navigation-fragment-ktx:$nav_version"
    implementation "android.arch.navigation:navigation-ui-ktx:$nav_version"
}
