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

Side by Side Diff: build/android/pylib/remote/device/remote_device_uirobot_run.py

Issue 840393003: Add support for ios_uirobot (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: bling -> ios Created 5 years, 11 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 unified diff | Download patch
OLDNEW
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 8 import os
9 import sys 9 import sys
10 10
(...skipping 19 matching lines...) Expand all
30 super(RemoteDeviceUirobotRun, self).__init__(env, test_instance) 30 super(RemoteDeviceUirobotRun, self).__init__(env, test_instance)
31 31
32 #override 32 #override
33 def TestPackage(self): 33 def TestPackage(self):
34 return self._test_instance.package_name 34 return self._test_instance.package_name
35 35
36 #override 36 #override
37 def _TriggerSetUp(self): 37 def _TriggerSetUp(self):
38 """Set up the triggering of a test run.""" 38 """Set up the triggering of a test run."""
39 logging.info('Triggering test run.') 39 logging.info('Triggering test run.')
40 self._app_id = self._UploadAppToDevice(self._test_instance.apk_under_test) 40 self._app_id = self._UploadAppToDevice(self._test_instance.app_under_test)
41 if not self._env.runner_type: 41 if not self._env.runner_type:
42 runner_type = self.DEFAULT_RUNNER_TYPE 42 runner_type = self.DEFAULT_RUNNER_TYPE
43 logging.info('Using default runner type: %s', self.DEFAULT_RUNNER_TYPE) 43 logging.info('Using default runner type: %s', self.DEFAULT_RUNNER_TYPE)
44 else: 44 else:
45 runner_type = self._env.runner_type 45 runner_type = self._env.runner_type
46 self._test_id = self._GetTestByName(runner_type) 46 self._test_id = self._GetTestByName(runner_type)
47 config_body = {'duration': self._test_instance.minutes} 47 config_body = {'duration': self._test_instance.minutes}
48 self._SetTestConfig(runner_type, config_body) 48 self._SetTestConfig(runner_type, config_body)
49 49
50 #override 50 #override
51 def _ParseTestResults(self): 51 def _ParseTestResults(self):
52 logging.info('Parsing results from remote service.') 52 logging.info('Parsing results from remote service.')
53 results = base_test_result.TestRunResults() 53 results = base_test_result.TestRunResults()
54 if self._results['results']['pass']: 54 if self._results['results']['pass']:
55 result_type = base_test_result.ResultType.PASS 55 result_type = base_test_result.ResultType.PASS
56 else: 56 else:
57 result_type = base_test_result.ResultType.FAIL 57 result_type = base_test_result.ResultType.FAIL
58 results.AddResult(base_test_result.BaseTestResult('uirobot', result_type)) 58 results.AddResult(base_test_result.BaseTestResult('uirobot', result_type))
59 return results 59 return results
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698