apply plugin: 'com.android.application'

android {
    compileSdkVersion rootProject.ext.compileSdkVersion

    defaultConfig {
        applicationId "com.esri.arcgisruntime.opensourceapps.nearbyplaces"
        minSdkVersion rootProject.ext.minSdkVersion
        targetSdkVersion rootProject.ext.targetSdkVersion
        versionCode 1
        versionName "1.0.11"

        testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
    }
    buildTypes {
        debug {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
            testProguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguardTest-rules.pro'
        }
        release {
            minifyEnabled true
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
            testProguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguardTest-rules.pro'
        }
    }

    // Always show the result of every unit test, even if it passes.
    testOptions.unitTests.all {
        testLogging {
            events 'passed', 'skipped', 'failed', 'standardOut', 'standardError'
        }
    }

    compileOptions {
        sourceCompatibility 1.8
        targetCompatibility 1.8
    }

    buildFeatures {
        viewBinding true
    }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    // App's dependencies, including test
    implementation "com.esri.arcgisruntime:arcgis-android:$rootProject.runtimeVersion"
    implementation "androidx.appcompat:appcompat:$rootProject.appcompatLibraryVersion"
    implementation "androidx.cardview:cardview:$rootProject.cardviewLibraryVersion"
    implementation "com.google.android.material:material:$rootProject.materialLibraryVersion"
    implementation "androidx.recyclerview:recyclerview:$rootProject.recyclerviewLibraryVersion"
    implementation "androidx.legacy:legacy-support-v4:$rootProject.legacyLibraryVersion"

    // Google location services
    implementation "com.google.android.gms:play-services-location:$rootProject.googleLocationServicesVersion"

}
