Skip to content

Commit 8c821b7

Browse files
author
Paige Mcauliffe
committed
Add testing sample for Espresso Device
1 parent 92d9c5f commit 8c821b7

File tree

3 files changed

+17
-1
lines changed

3 files changed

+17
-1
lines changed

projects.conf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ ui/espresso/AccessibilitySample
55
ui/espresso/BasicSample
66
ui/espresso/CustomMatcherSample
77
ui/espresso/DataAdapterSample
8+
ui/espresso/EspressoDeviceSample
89
ui/espresso/FragmentScenarioSample
910
ui/espresso/IdlingResourceSample
1011
ui/espresso/IntentsAdvancedSample
@@ -15,4 +16,4 @@ ui/espresso/RecyclerViewSample
1516
ui/espresso/ScreenshotSample
1617
ui/espresso/WebBasicSample
1718
ui/uiautomator/BasicSample
18-
unit/BasicNativeAndroidTest
19+
unit/BasicNativeAndroidTest

ui/espresso/EspressoDeviceSample/app/build.gradle

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,20 @@ android {
2525
unitTests {
2626
includeAndroidResources = true
2727
}
28+
managedDevices {
29+
devices {
30+
// run with ../gradlew nexusOneApi30DebugAndroidTest
31+
nexusOneApi30(com.android.build.api.dsl.ManagedVirtualDevice) {
32+
// A lower resolution device is used here for better emulator performance
33+
device = "Nexus One"
34+
apiLevel = 30
35+
// Also use the AOSP ATD image for better emulator performance
36+
// The androidx.test screenshot APIs will automatically enable hardware rendering
37+
// to take a screenshot
38+
systemImageSource = "aosp-atd"
39+
}
40+
}
41+
}
2842
}
2943
}
3044

update_versions.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ coreVersion="1.5.0-beta01" # CORE_VERSION
3030
extJUnitVersion="1.1.4-beta01" # ANDROIDX_JUNIT_VERSION
3131
extTruthVersion="1.5.0-beta01" # ANDROIDX_TRUTH_VERSION
3232
espressoVersion="3.5.0-beta01" # ESPRESSO_VERSION
33+
espressoDeviceVersion="1.0.0-alpha01" # ESPRESSO_DEVICE_VERSION
3334
robolectricVersion="4.9"
3435
uiAutomatorVersion="2.2.0" # UIAUTOMATOR_VERSION
3536

0 commit comments

Comments
 (0)