| OLD | NEW |
| 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 import unittest | 4 import unittest |
| 5 | 5 |
| 6 from chrome_remote_control import android_browser_finder | 6 from telemetry import android_browser_finder |
| 7 from chrome_remote_control import browser_options | 7 from telemetry import browser_options |
| 8 from chrome_remote_control import system_stub | 8 from telemetry import system_stub |
| 9 | 9 |
| 10 class LoggingStub(object): | 10 class LoggingStub(object): |
| 11 def __init__(self): | 11 def __init__(self): |
| 12 self.warnings = [] | 12 self.warnings = [] |
| 13 | 13 |
| 14 def info(self, msg, *args): | 14 def info(self, msg, *args): |
| 15 pass | 15 pass |
| 16 | 16 |
| 17 def warn(self, msg, *args): | 17 def warn(self, msg, *args): |
| 18 self.warnings.append(msg % args) | 18 self.warnings.append(msg % args) |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 assert args[0] == 'pm' | 79 assert args[0] == 'pm' |
| 80 assert args[1] == 'list' | 80 assert args[1] == 'list' |
| 81 assert args[2] == 'packages' | 81 assert args[2] == 'packages' |
| 82 return ['package:org.chromium.content_shell', | 82 return ['package:org.chromium.content_shell', |
| 83 'package.com.google.android.setupwizard'] | 83 'package.com.google.android.setupwizard'] |
| 84 | 84 |
| 85 self._stubs.adb_commands.shell_command_handlers['pm'] = OnPM | 85 self._stubs.adb_commands.shell_command_handlers['pm'] = OnPM |
| 86 | 86 |
| 87 browsers = android_browser_finder.FindAllAvailableBrowsers(options) | 87 browsers = android_browser_finder.FindAllAvailableBrowsers(options) |
| 88 self.assertEquals(1, len(browsers)) | 88 self.assertEquals(1, len(browsers)) |
| OLD | NEW |