| Index: build/android/pylib/remote/device/remote_device_uirobot_run.py
|
| diff --git a/build/android/pylib/remote/device/remote_device_uirobot_run.py b/build/android/pylib/remote/device/remote_device_uirobot_run.py
|
| index d2d6f36431a62014f6e4d8ba054c63a6d6bdbe3d..3aee3433077a95b7531a010b1175a02cbda3ada6 100644
|
| --- a/build/android/pylib/remote/device/remote_device_uirobot_run.py
|
| +++ b/build/android/pylib/remote/device/remote_device_uirobot_run.py
|
| @@ -10,15 +10,10 @@ import sys
|
|
|
| from pylib import constants
|
| from pylib.base import base_test_result
|
| +from pylib.remote.device import appurify_sanitized
|
| from pylib.remote.device import remote_device_test_run
|
| from pylib.remote.device import remote_device_helper
|
|
|
| -sys.path.append(os.path.join(
|
| - constants.DIR_SOURCE_ROOT, 'third_party', 'requests', 'src'))
|
| -sys.path.append(os.path.join(
|
| - constants.DIR_SOURCE_ROOT, 'third_party', 'appurify-python', 'src'))
|
| -import appurify.api
|
| -import appurify.utils
|
|
|
| class RemoteDeviceUirobotRun(remote_device_test_run.RemoteDeviceTestRun):
|
| """Run uirobot tests on a remote device."""
|
| @@ -34,12 +29,14 @@ class RemoteDeviceUirobotRun(remote_device_test_run.RemoteDeviceTestRun):
|
| """
|
| super(RemoteDeviceUirobotRun, self).__init__(env, test_instance)
|
|
|
| + #override
|
| def TestPackage(self):
|
| - pass
|
| + return self._test_instance.package_name
|
|
|
| #override
|
| def _TriggerSetUp(self):
|
| """Set up the triggering of a test run."""
|
| + logging.info('Triggering test run.')
|
| self._app_id = self._UploadAppToDevice(self._test_instance.apk_under_test)
|
| if not self._env.runner_type:
|
| runner_type = self.DEFAULT_RUNNER_TYPE
|
| @@ -52,7 +49,11 @@ class RemoteDeviceUirobotRun(remote_device_test_run.RemoteDeviceTestRun):
|
|
|
| #override
|
| def _ParseTestResults(self):
|
| - # TODO(rnephew): Populate test results object.
|
| - results = remote_device_test_run.TestRunResults()
|
| + logging.info('Parsing results from remote service.')
|
| + results = base_test_result.TestRunResults()
|
| + if self._results['results']['pass']:
|
| + result_type = base_test_result.ResultType.PASS
|
| + else:
|
| + result_type = base_test_result.ResultType.FAIL
|
| + results.AddResult(base_test_result.BaseTestResult('uirobot', result_type))
|
| return results
|
| -
|
|
|