| 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 """Run specific test on specific environment.""" | 5 """Run specific test on specific environment.""" |
| 6 | 6 |
| 7 import logging | 7 import logging |
| 8 import os | |
| 9 import sys | |
| 10 | 8 |
| 11 from pylib import constants | |
| 12 from pylib.base import base_test_result | 9 from pylib.base import base_test_result |
| 13 from pylib.remote.device import appurify_sanitized | 10 from pylib.remote.device import appurify_sanitized |
| 14 from pylib.remote.device import remote_device_test_run | 11 from pylib.remote.device import remote_device_test_run |
| 15 from pylib.remote.device import remote_device_helper | 12 from pylib.remote.device import remote_device_helper |
| 16 | 13 |
| 17 | 14 |
| 18 class RemoteDeviceUirobotTestRun(remote_device_test_run.RemoteDeviceTestRun): | 15 class RemoteDeviceUirobotTestRun(remote_device_test_run.RemoteDeviceTestRun): |
| 19 """Run uirobot tests on a remote device.""" | 16 """Run uirobot tests on a remote device.""" |
| 20 | 17 |
| 21 | 18 |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 #override | 76 #override |
| 80 def _ParseTestResults(self): | 77 def _ParseTestResults(self): |
| 81 logging.info('Parsing results from remote service.') | 78 logging.info('Parsing results from remote service.') |
| 82 results = base_test_result.TestRunResults() | 79 results = base_test_result.TestRunResults() |
| 83 if self._results['results']['pass']: | 80 if self._results['results']['pass']: |
| 84 result_type = base_test_result.ResultType.PASS | 81 result_type = base_test_result.ResultType.PASS |
| 85 else: | 82 else: |
| 86 result_type = base_test_result.ResultType.FAIL | 83 result_type = base_test_result.ResultType.FAIL |
| 87 results.AddResult(base_test_result.BaseTestResult('uirobot', result_type)) | 84 results.AddResult(base_test_result.BaseTestResult('uirobot', result_type)) |
| 88 return results | 85 return results |
| OLD | NEW |