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

Unified Diff: build/android/pylib/valgrind_tools.py

Issue 285143002: [Android] Convert to DeviceUtils versions of IsOnline, HasRoot, and EnableRoot. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
Index: build/android/pylib/valgrind_tools.py
diff --git a/build/android/pylib/valgrind_tools.py b/build/android/pylib/valgrind_tools.py
index 22ac39b4ba2247a76e25e93fdfcde3dcbba4185d..e6573b4df96ca244f994d0d40e16d7255c71b8ff 100644
--- a/build/android/pylib/valgrind_tools.py
+++ b/build/android/pylib/valgrind_tools.py
@@ -28,6 +28,7 @@ import subprocess
import sys
from pylib.constants import DIR_SOURCE_ROOT
+from pylib.device import device_errors
def SetChromeTimeoutScale(device, scale):
@@ -132,7 +133,11 @@ class AddressSanitizerTool(BaseTool):
return self.GetTestWrapper()
def SetupEnvironment(self):
- self._device.old_interface.EnableAdbRoot()
+ try:
+ self._device.EnableRoot()
+ except device_errors.CommandFailedError:
+ # Try to set the timeout scale anyway.
+ pass
SetChromeTimeoutScale(self._device, self.GetTimeoutScale())
def CleanUpEnvironment(self):

Powered by Google App Engine
This is Rietveld 408576698