From a76d883a0dca39cd6a908ab272c6b0b8cf2c5046 Mon Sep 17 00:00:00 2001 From: Yuri Schimke Date: Wed, 3 Jan 2024 11:39:16 +0000 Subject: [PATCH] Add FTL devices to AlwaysOnKotlin --- AlwaysOnKotlin/build.gradle | 1 + AlwaysOnKotlin/compose/build.gradle | 19 +++++++++++++++---- AlwaysOnKotlin/gradle.properties | 1 + AlwaysOnKotlin/gradle/libs.versions.toml | 1 + 4 files changed, 18 insertions(+), 4 deletions(-) diff --git a/AlwaysOnKotlin/build.gradle b/AlwaysOnKotlin/build.gradle index ca87b890b..b04575bb7 100644 --- a/AlwaysOnKotlin/build.gradle +++ b/AlwaysOnKotlin/build.gradle @@ -23,6 +23,7 @@ buildscript { plugins { alias(libs.plugins.com.diffplug.spotless) apply(false) alias(libs.plugins.com.android.application) apply(false) + alias(libs.plugins.firebase.testlab) apply (false) } subprojects { diff --git a/AlwaysOnKotlin/compose/build.gradle b/AlwaysOnKotlin/compose/build.gradle index 63a63da58..c11db6743 100644 --- a/AlwaysOnKotlin/compose/build.gradle +++ b/AlwaysOnKotlin/compose/build.gradle @@ -1,3 +1,5 @@ +import com.android.build.api.dsl.ManagedVirtualDevice + /* * Copyright (C) 2021 The Android Open Source Project * @@ -17,6 +19,7 @@ plugins { id 'com.android.application' id 'org.jetbrains.kotlin.android' + id "com.google.firebase.testlab" } android { @@ -78,23 +81,31 @@ android { } testOptions { + firebaseTestLab { + managedDevices { + pixelWatch { + device = "r11" + apiLevel = 30 + } + } + } devices { - squareApi30(com.android.build.api.dsl.ManagedVirtualDevice) { + squareApi30(ManagedVirtualDevice) { device = "Wear OS Square" apiLevel = 30 systemImageSource = "android-wear" } - roundApi28(com.android.build.api.dsl.ManagedVirtualDevice) { + roundApi28(ManagedVirtualDevice) { device = "Wear OS Large Round" apiLevel = 28 systemImageSource = "android-wear" } - roundApi30(com.android.build.api.dsl.ManagedVirtualDevice) { + roundApi30(ManagedVirtualDevice) { device = "Wear OS Large Round" apiLevel = 30 systemImageSource = "android-wear" } - roundApi33(com.android.build.api.dsl.ManagedVirtualDevice) { + roundApi33(ManagedVirtualDevice) { device = "Wear OS Large Round" apiLevel = 33 systemImageSource = "android-wear" diff --git a/AlwaysOnKotlin/gradle.properties b/AlwaysOnKotlin/gradle.properties index 538ff2e2b..1d70c5413 100644 --- a/AlwaysOnKotlin/gradle.properties +++ b/AlwaysOnKotlin/gradle.properties @@ -4,3 +4,4 @@ android.useAndroidX=true android.sdk.channel=3 # https://buganizer.corp.google.com/issues/311218673 android.experimental.lint.version=8.3.0-alpha14 +android.experimental.testOptions.managedDevices.customDevice=true diff --git a/AlwaysOnKotlin/gradle/libs.versions.toml b/AlwaysOnKotlin/gradle/libs.versions.toml index ea7707de7..c2d991930 100644 --- a/AlwaysOnKotlin/gradle/libs.versions.toml +++ b/AlwaysOnKotlin/gradle/libs.versions.toml @@ -47,3 +47,4 @@ wearable = { module = "com.google.android.wearable:wearable", version.ref = "wea [plugins] com-android-application = { id = "com.android.application", version.ref = "android-gradle-plugin" } com-diffplug-spotless = "com.diffplug.spotless:6.23.3" +firebase-testlab = "com.google.firebase.testlab:0.0.1-alpha05"