Files
coco 723ce1af5c a
2026-07-03 15:12:48 +08:00

52 lines
1.3 KiB
Groovy

plugins {
id 'com.android.test'
id 'kotlin-android'
}
android {
compileSdkVersion Versions.COMPILE_SDK
defaultConfig {
minSdkVersion 23 // Macrobenchmark doesn't work on lower API
targetSdkVersion Versions.TARGET_SDK
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
buildTypes {
// declare a build type to match the target app's build type
benchmark {
debuggable = true
signingConfig = debug.signingConfig
}
}
targetProjectPath = ":mobile"
experimentalProperties["android.experimental.self-instrumenting"] = true
}
androidComponents {
beforeVariants(selector().all()) {
// enable only the release buildType, since we only want to measure
// release build performance
enabled = buildType == 'benchmark'
}
}
dependencies {
api platform(project(":depconstraints"))
implementation Libs.BENCHMARK_MACRO
implementation Libs.ESPRESSO_CORE
implementation Libs.EXT_JUNIT
implementation Libs.KOTLIN_STDLIB
implementation Libs.TIMBER
implementation Libs.UI_AUTOMATOR
}