plugins {
    id 'com.android.library'
    id 'kotlin-android'
}

android {
    namespace = 'com.frolo.player.android'
    compileSdkVersion versions.compileSdk

    defaultConfig {
        minSdkVersion versions.minSdk
        targetSdkVersion versions.targetSdk

        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    buildTypes {
        debug {
        }

        release {
        }
    }

    packagingOptions {
        exclude 'META-INF/api_debug.kotlin_module'
    }
}

kotlin {
    jvmToolchain(buildtools.versions.java.get().toInteger())
}

java {
    toolchain {
        languageVersion.set(JavaLanguageVersion.of(buildtools.versions.java.get()))
    }
}

dependencies {
    api project(path: ':audio:player:api')
    implementation project(path: ':audio:player:data')

    implementation deps.support.annotation

    // Instrumentation tests
    androidTestImplementation deps.test.runner
    androidTestImplementation deps.test.rules
    androidTestImplementation 'org.mockito:mockito-core:2.23.0'
    androidTestImplementation 'org.mockito:mockito-android:2.23.0'
    androidTestImplementation "com.nhaarman.mockitokotlin2:mockito-kotlin:2.1.0"
    androidTestImplementation project(path: ':test-tools:stubs')
    androidTestImplementation project(path: ':test-tools:assets')
}
