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

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

Issue 1281923003: [Android] Add --blacklist-file as a command-line option. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix telemetry_unittests Created 5 years, 4 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 | « build/android/pylib/instrumentation/test_jar.py ('k') | build/android/pylib/perf/perf_control_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/pylib/local/device/local_device_environment.py
diff --git a/build/android/pylib/local/device/local_device_environment.py b/build/android/pylib/local/device/local_device_environment.py
index 04f9ab7d2fead494c5d90759e30ae90b048fc0e8..4a0d5672173da57826b3d9d8ed36befe13d9defa 100644
--- a/build/android/pylib/local/device/local_device_environment.py
+++ b/build/android/pylib/local/device/local_device_environment.py
@@ -4,6 +4,7 @@
from pylib.base import environment
from pylib.device import adb_wrapper
+from pylib.device import device_blacklist
from pylib.device import device_errors
from pylib.device import device_utils
from pylib.utils import parallelizer
@@ -13,6 +14,8 @@ class LocalDeviceEnvironment(environment.Environment):
def __init__(self, args, _error_func):
super(LocalDeviceEnvironment, self).__init__()
+ self._blacklist = device_blacklist.Blacklist(
+ args.blacklist_file or device_blacklist.BLACKLIST_JSON)
self._device_serial = args.test_device
self._devices = []
self._max_tries = 1 + args.num_retries
@@ -20,7 +23,8 @@ class LocalDeviceEnvironment(environment.Environment):
#override
def SetUp(self):
- available_devices = device_utils.DeviceUtils.HealthyDevices()
+ available_devices = device_utils.DeviceUtils.HealthyDevices(
+ self._blacklist)
if not available_devices:
raise device_errors.NoDevicesError
if self._device_serial:
« no previous file with comments | « build/android/pylib/instrumentation/test_jar.py ('k') | build/android/pylib/perf/perf_control_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698