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

Unified Diff: build/android/adb_install_apk.py

Issue 1083403002: [Android] Remove android_commands uses from build/android/. (reland) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixed Created 5 years, 8 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 | build/android/adb_reverse_forwarder.py » ('j') | build/android/pylib/device/adb_wrapper.py » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/adb_install_apk.py
diff --git a/build/android/adb_install_apk.py b/build/android/adb_install_apk.py
index 5d0fd171494090e70247d0552a4cf3d4f2bb6c33..b6da19ef2691bb8185080a42e5c59905a418cab1 100755
--- a/build/android/adb_install_apk.py
+++ b/build/android/adb_install_apk.py
@@ -10,8 +10,9 @@ import optparse
import os
import sys
-from pylib import android_commands
from pylib import constants
+from pylib.device import adb_wrapper
+from pylib.device import device_filter
from pylib.device import device_utils
@@ -71,10 +72,11 @@ def main(argv):
constants.SetBuildType(options.build_type)
ValidateInstallAPKOption(parser, options, args)
- devices = android_commands.GetAttachedDevices()
+ devices = adb_wrapper.AdbWrapper.Devices(
+ filters=device_filter.DefaultFilters())
if options.device:
- if options.device not in devices:
+ if options.device not in [d.GetDeviceSerial() for d in devices]:
raise Exception('Error: %s not in attached devices %s' % (options.device,
','.join(devices)))
devices = [options.device]
« no previous file with comments | « no previous file | build/android/adb_reverse_forwarder.py » ('j') | build/android/pylib/device/adb_wrapper.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698