OLD | NEW |
---|---|
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 """ | 5 """ |
6 Exception classes raised by AdbWrapper and DeviceUtils. | 6 Exception classes raised by AdbWrapper and DeviceUtils. |
7 """ | 7 """ |
8 | 8 |
9 from devil import base_error | 9 from devil import base_error |
10 from devil.utils import cmd_helper | 10 from devil.utils import cmd_helper |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
108 super(NoDevicesError, self).__init__( | 108 super(NoDevicesError, self).__init__( |
109 'No devices attached.', is_infra_error=True) | 109 'No devices attached.', is_infra_error=True) |
110 | 110 |
111 | 111 |
112 class NoAdbError(base_error.BaseError): | 112 class NoAdbError(base_error.BaseError): |
113 """Exception for being unable to find ADB.""" | 113 """Exception for being unable to find ADB.""" |
114 | 114 |
115 def __init__(self, msg=None): | 115 def __init__(self, msg=None): |
116 super(NoAdbError, self).__init__( | 116 super(NoAdbError, self).__init__( |
117 msg or 'Unable to find adb.', is_infra_error=True) | 117 msg or 'Unable to find adb.', is_infra_error=True) |
118 | |
jbudorick
2016/02/05 01:40:43
nit: +1 blank line
rnephew (Reviews Here)
2016/02/05 01:52:00
Done.
| |
119 class DeviceChargingError(CommandFailedError): | |
120 """Exception for device charging errors.""" | |
121 | |
122 def __init__(self, message, device_serial=None): | |
123 super(DeviceChargingError, self).__init__(message, device_serial) | |
OLD | NEW |