add macrobenchmark
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
plugins {
|
||||
alias(libs.plugins.android.test)
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "com.bitcointxoko.gudariwallet.macrobenchmark"
|
||||
compileSdk = 36
|
||||
|
||||
defaultConfig {
|
||||
minSdk = 26
|
||||
targetSdk = 36
|
||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||
// because GrapheneOS restricts tracefs access, which is used by Perfetto
|
||||
// testInstrumentationRunnerArguments["androidx.benchmark.suppressErrors"] =
|
||||
"DEVICE-TRACING-MISCONFIGURED"
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
create("benchmark") {
|
||||
isDebuggable = true
|
||||
signingConfig = getByName("debug").signingConfig
|
||||
matchingFallbacks += listOf("release")
|
||||
}
|
||||
}
|
||||
|
||||
targetProjectPath = ":app"
|
||||
experimentalProperties["android.experimental.self-instrumenting"] = true
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(libs.androidx.benchmark.macro.junit4)
|
||||
implementation(libs.androidx.test.ext.junit)
|
||||
implementation(libs.androidx.test.uiautomator)
|
||||
}
|
||||
|
||||
androidComponents {
|
||||
beforeVariants(selector().all()) {
|
||||
it.enable = it.buildType == "benchmark"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user