Skip to content

Commit b74ae14

Browse files
committed
Migrate benchmark plugin to 1.2.0 stable
1 parent 6cb29a0 commit b74ae14

File tree

3 files changed

+7
-13
lines changed

3 files changed

+7
-13
lines changed

benchmark/build.gradle.kts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ android {
4646
}
4747

4848
targetProjectPath = ":app"
49-
experimentalProperties["android.experimental.self-instrumenting"] = true
5049
}
5150

5251
dependencies {
@@ -55,9 +54,3 @@ dependencies {
5554
implementation(libs.androidx.benchmark.macro)
5655
implementation(libs.androidx.profileinstaller)
5756
}
58-
59-
androidComponents {
60-
beforeVariants(selector().all()) {
61-
it.enabled = it.buildType == "benchmark"
62-
}
63-
}

benchmark/src/main/kotlin/io/getstream/whatsappclone/benchmark/BaselineProfileGenerator.kt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,22 +16,23 @@
1616

1717
package io.getstream.whatsappclone.benchmark
1818

19-
import androidx.benchmark.macro.ExperimentalBaselineProfilesApi
19+
import android.os.Build
20+
import androidx.annotation.RequiresApi
2021
import androidx.benchmark.macro.junit4.BaselineProfileRule
2122
import org.junit.Rule
2223
import org.junit.Test
2324

2425
/**
2526
* Generates a baseline profile which can be copied to `app/src/main/baseline-prof.txt`.
2627
*/
27-
@ExperimentalBaselineProfilesApi
28+
@RequiresApi(Build.VERSION_CODES.P)
2829
class BaselineProfileGenerator {
2930
@get:Rule
3031
val baselineProfileRule = BaselineProfileRule()
3132

3233
@Test
3334
fun startup() =
34-
baselineProfileRule.collectBaselineProfile(
35+
baselineProfileRule.collect(
3536
packageName = "io.getstream.whatsappclone"
3637
) {
3738
pressHome()

gradle/libs.versions.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,15 @@ androidDesugarJdkLibs = "1.1.5"
88
androidGradlePlugin = "8.1.2"
99
androidxActivity = "1.8.0"
1010
androidxAppCompat = "1.6.1"
11-
androidxCompose = "1.5.3"
11+
androidxCompose = "1.5.4"
1212
androidxComposeCompiler = "1.5.3"
1313
androidxComposeMaterial3 = "1.0.0-alpha13"
1414
androidxComposeConstraintLayout = "1.0.1"
1515
androidxComposeNavigation = "2.5.3"
1616
androidxCore = "1.12.0"
1717
androidxHiltNavigationCompose = "1.0.0"
1818
androidxLifecycle = "2.6.2"
19-
androidxMacroBenchmark = "1.1.1"
19+
androidxMacroBenchmark = "1.2.0"
2020
androidxNavigation = "2.5.0"
2121
androidxProfileinstaller = "1.3.1"
2222
androidxStartup = "1.1.1"
@@ -34,7 +34,7 @@ kotlinxCoroutines = "1.7.3"
3434
kotlinxSerializationJson = "1.6.0"
3535
ksp = "1.9.10-1.0.13"
3636
ktlint = "0.43.0"
37-
okhttp = "4.11.0"
37+
okhttp = "4.12.0"
3838
retrofit = "2.9.0"
3939
retrofitResultAdapter = "1.0.9"
4040
retrofitKotlinxSerializationJson = "1.0.0"

0 commit comments

Comments
 (0)