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

Side by Side Diff: build/android/pylib/device/device_utils.py

Issue 1211323004: [Telemetry] Remove adb_commands usage from android_device (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | tools/telemetry/telemetry/core/platform/android_device.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """Provides a variety of device interactions based on adb. 5 """Provides a variety of device interactions based on adb.
6 6
7 Eventually, this will be based on adb_wrapper. 7 Eventually, this will be based on adb_wrapper.
8 """ 8 """
9 # pylint: disable=unused-argument 9 # pylint: disable=unused-argument
10 10
(...skipping 1726 matching lines...) Expand 10 before | Expand all | Expand 10 after
1737 def HealthyDevices(cls): 1737 def HealthyDevices(cls):
1738 blacklist = device_blacklist.ReadBlacklist() 1738 blacklist = device_blacklist.ReadBlacklist()
1739 def blacklisted(adb): 1739 def blacklisted(adb):
1740 if adb.GetDeviceSerial() in blacklist: 1740 if adb.GetDeviceSerial() in blacklist:
1741 logging.warning('Device %s is blacklisted.', adb.GetDeviceSerial()) 1741 logging.warning('Device %s is blacklisted.', adb.GetDeviceSerial())
1742 return True 1742 return True
1743 return False 1743 return False
1744 1744
1745 return [cls(adb) for adb in adb_wrapper.AdbWrapper.Devices() 1745 return [cls(adb) for adb in adb_wrapper.AdbWrapper.Devices()
1746 if not blacklisted(adb)] 1746 if not blacklisted(adb)]
1747
1748 @classmethod
1749 def GetAttachedDevices(cls):
jbudorick 2015/06/29 17:56:23 I would prefer to not add this here. Generally, cl
nednguyen 2015/06/29 17:59:12 Ok. But I am curious about this black listing stra
jbudorick 2015/06/29 18:03:45 ...? We don't have a hard-coded list of device ID
nednguyen 2015/06/29 18:14:54 By hard coded, I mean the path to json file bad_de
jbudorick 2015/06/29 18:27:44 Oh, yeah. That part is hard-coded, but I don't thi
nednguyen 2015/06/29 18:42:05 Done.
1750 return [cls(adb) for adb in adb_wrapper.AdbWrapper.Devices()]
OLDNEW
« no previous file with comments | « no previous file | tools/telemetry/telemetry/core/platform/android_device.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698