aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorConnor O'Brien <connoro@google.com>2017-09-12 14:54:54 -0700
committerConnor O'Brien <connoro@google.com>2017-12-15 19:26:46 -0800
commitaae7d87c9ff7db824434223d5d9ec0e06f58fe36 (patch)
tree04db4d2145dea382d20fb463240a98d27c218970
parent2fbced9df5a7df099f25e176c977d02b26dd3da7 (diff)
downloadlisa-aae7d87c9ff7db824434223d5d9ec0e06f58fe36.tar.gz
LISA: make SysUi workload use package list
The Workload class can now automatically install missing dependencies stored in a workload's "packages" variable. Modify the SystemUi workload to allow installing UbSystemUiJankTests automatically. Also eliminate the "package" variable since the device will always have the SystemUi package installed. Test: Ran ./experiments/runsysui.py on a device without the tests installed Change-Id: I415f0dd9309d5572ccacfdcceb91eff10cdb478c Signed-off-by: Connor O'Brien <connoro@google.com>
-rw-r--r--libs/utils/android/workloads/systemui.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/libs/utils/android/workloads/systemui.py b/libs/utils/android/workloads/systemui.py
index 9e46631..6aea799 100644
--- a/libs/utils/android/workloads/systemui.py
+++ b/libs/utils/android/workloads/systemui.py
@@ -31,10 +31,15 @@ class SystemUi(Workload):
Android SystemUi jank test workload
"""
- package = 'com.android.systemui'
+ # Packages required by this workload
+ packages = [
+ Workload.WorkloadPackage("android.platform.systemui.tests.jank",
+ "data/app/UbSystemUiJankTests/UbSystemUiJankTests.apk",
+ "platform_testing/tests/jank/UbSystemUiJankTests")
+ ]
# Instrumentation required to run tests
- test_package = 'android.platform.systemui.tests.jank'
+ test_package = packages[0].package_name
test_list = \
["LauncherJankTests#testOpenAllAppsContainer",
@@ -110,9 +115,6 @@ class SystemUi(Workload):
# Unlock device screen (assume no password required)
Screen.unlock(self._target)
- # Close and clear application
- System.force_stop(self._target, self.package, clear=True)
-
# Set airplane mode
System.set_airplane_mode(self._target, on=True)