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 hashlib | 8 import hashlib |
9 import json | 9 import json |
10 import os | 10 import os |
(...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
407 | 407 |
408 if not bb_utils.TESTING: | 408 if not bb_utils.TESTING: |
409 # Restart adb to work around bugs, sleep to wait for usb discovery. | 409 # Restart adb to work around bugs, sleep to wait for usb discovery. |
410 device_utils.RestartServer() | 410 device_utils.RestartServer() |
411 RunCmd(['sleep', '1']) | 411 RunCmd(['sleep', '1']) |
412 provision_cmd = ['build/android/provision_devices.py', '-t', options.target] | 412 provision_cmd = ['build/android/provision_devices.py', '-t', options.target] |
413 if options.auto_reconnect: | 413 if options.auto_reconnect: |
414 provision_cmd.append('--auto-reconnect') | 414 provision_cmd.append('--auto-reconnect') |
415 if options.skip_wipe: | 415 if options.skip_wipe: |
416 provision_cmd.append('--skip-wipe') | 416 provision_cmd.append('--skip-wipe') |
417 RunCmd(provision_cmd) | 417 RunCmd(provision_cmd, halt_on_failure=True) |
418 | 418 |
419 | 419 |
420 def DeviceStatusCheck(options): | 420 def DeviceStatusCheck(options): |
421 bb_annotations.PrintNamedStep('device_status_check') | 421 bb_annotations.PrintNamedStep('device_status_check') |
422 cmd = ['build/android/buildbot/bb_device_status_check.py'] | 422 cmd = ['build/android/buildbot/bb_device_status_check.py'] |
423 if options.restart_usb: | 423 if options.restart_usb: |
424 cmd.append('--restart-usb') | 424 cmd.append('--restart-usb') |
425 RunCmd(cmd, halt_on_failure=True) | 425 RunCmd(cmd, halt_on_failure=True) |
426 | 426 |
427 | 427 |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
689 | 689 |
690 if options.coverage_bucket: | 690 if options.coverage_bucket: |
691 setattr(options, 'coverage_dir', | 691 setattr(options, 'coverage_dir', |
692 os.path.join(CHROME_OUT_DIR, options.target, 'coverage')) | 692 os.path.join(CHROME_OUT_DIR, options.target, 'coverage')) |
693 | 693 |
694 MainTestWrapper(options) | 694 MainTestWrapper(options) |
695 | 695 |
696 | 696 |
697 if __name__ == '__main__': | 697 if __name__ == '__main__': |
698 sys.exit(main(sys.argv)) | 698 sys.exit(main(sys.argv)) |
OLD | NEW |