Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(519)

Unified Diff: build/android/pylib/local/device/local_device_instrumentation_test_run.py

Issue 1952813002: [Android] Set permissions when clearing app state in test runner platform mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/local/device/local_device_instrumentation_test_run.py
diff --git a/build/android/pylib/local/device/local_device_instrumentation_test_run.py b/build/android/pylib/local/device/local_device_instrumentation_test_run.py
index fd7cfbbad34d80352cac2630712f3eeeac0e139f..2d574de1fd2017149062cb63c9c4eb12e6023bad 100644
--- a/build/android/pylib/local/device/local_device_instrumentation_test_run.py
+++ b/build/android/pylib/local/device/local_device_instrumentation_test_run.py
@@ -268,7 +268,13 @@ class LocalDeviceInstrumentationTestRun(
logging.info(' %s', l)
if (not self._env.skip_clear_data
and self._test_instance.package_info):
- device.ClearApplicationState(self._test_instance.package_info.package)
+ permissions = (
+ self._test_instance.apk_under_test.GetPermissions()
+ if self._test_instance.apk_under_test
+ else None)
+ device.ClearApplicationState(self._test_instance.package_info.package,
+ permissions=permissions)
+
else:
logging.debug('raw output from %s:', test_display_name)
for l in output:
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698