OLD | NEW |
---|---|
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import collections | 6 import collections |
7 import glob | 7 import glob |
8 import json | 8 import json |
9 import multiprocessing | 9 import multiprocessing |
10 import optparse | 10 import optparse |
(...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
257 # Wait for logcat_monitor to pull existing logcat | 257 # Wait for logcat_monitor to pull existing logcat |
258 RunCmd(['sleep', '5']) | 258 RunCmd(['sleep', '5']) |
259 | 259 |
260 if options.reboot: | 260 if options.reboot: |
261 RebootDevices() | 261 RebootDevices() |
262 | 262 |
263 # Device check and alert emails | 263 # Device check and alert emails |
264 buildbot_report.PrintNamedStep('device_status_check') | 264 buildbot_report.PrintNamedStep('device_status_check') |
265 RunCmd(['build/android/device_status_check.py'], flunk_on_failure=False) | 265 RunCmd(['build/android/device_status_check.py'], flunk_on_failure=False) |
266 | 266 |
267 # Provision devices | |
268 buildername = options.build_properties.get('buildername', '') | |
269 if buildername == 'Android GN (stats)': | |
Siva Chandra
2013/03/15 02:01:52
This if is a temporary. It will go away after we t
| |
270 buildbot_report.PrintNamedStep('provision_devices') | |
271 adb_reboot = 'out/%s/adb_reboot' % options.factory_properties['target'] | |
272 cmd = ['build/android/provision_devices.py -a %s' % adb_reboot] | |
273 RunCmd(cmd, flunk_on_failure=False) | |
274 | |
267 if options.install: | 275 if options.install: |
268 test_obj = INSTRUMENTATION_TESTS[options.install] | 276 test_obj = INSTRUMENTATION_TESTS[options.install] |
269 InstallApk(options, test_obj, print_step=True) | 277 InstallApk(options, test_obj, print_step=True) |
270 | 278 |
271 if 'chromedriver' in options.test_filter: | 279 if 'chromedriver' in options.test_filter: |
272 RunChromeDriverTests() | 280 RunChromeDriverTests() |
273 if 'unit' in options.test_filter: | 281 if 'unit' in options.test_filter: |
274 RunTestSuites(options, gtest_config.STABLE_TEST_SUITES) | 282 RunTestSuites(options, gtest_config.STABLE_TEST_SUITES) |
275 if 'ui' in options.test_filter: | 283 if 'ui' in options.test_filter: |
276 for test in INSTRUMENTATION_TESTS.itervalues(): | 284 for test in INSTRUMENTATION_TESTS.itervalues(): |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
353 'slave', 'android')) | 361 'slave', 'android')) |
354 if os.path.exists(build_internal_android): | 362 if os.path.exists(build_internal_android): |
355 android_paths.insert(0, build_internal_android) | 363 android_paths.insert(0, build_internal_android) |
356 os.environ['PATH'] = os.pathsep.join(android_paths + [os.environ['PATH']]) | 364 os.environ['PATH'] = os.pathsep.join(android_paths + [os.environ['PATH']]) |
357 | 365 |
358 MainTestWrapper(options) | 366 MainTestWrapper(options) |
359 | 367 |
360 | 368 |
361 if __name__ == '__main__': | 369 if __name__ == '__main__': |
362 sys.exit(main(sys.argv)) | 370 sys.exit(main(sys.argv)) |
OLD | NEW |