[Android] Remove adb_commands from telemetry.
[chromium-blink-merge.git] / build / android / bb_run_sharded_steps.py
blob6aeba5b5f58cfeccf7d835e6613afbb632ea18b1
1 #!/usr/bin/env python
3 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file.
7 """DEPRECATED!
8 TODO(bulach): remove me once all other repositories reference
9 'test_runner.py perf' directly.
10 """
12 import optparse
13 import sys
15 from pylib import cmd_helper
18 def main(argv):
19 parser = optparse.OptionParser()
20 parser.add_option('-s', '--steps',
21 help='A JSON file containing all the steps to be '
22 'sharded.')
23 parser.add_option('--flaky_steps',
24 help='A JSON file containing steps that are flaky and '
25 'will have its exit code ignored.')
26 parser.add_option('-p', '--print_results',
27 help='Only prints the results for the previously '
28 'executed step, do not run it again.')
29 options, _ = parser.parse_args(argv)
30 if options.print_results:
31 return cmd_helper.RunCmd(['build/android/test_runner.py', 'perf',
32 '--print-step', options.print_results])
33 flaky_options = []
34 if options.flaky_steps:
35 flaky_options = ['--flaky-steps', options.flaky_steps]
36 return cmd_helper.RunCmd(['build/android/test_runner.py', 'perf', '-v',
37 '--steps', options.steps] + flaky_options)
40 if __name__ == '__main__':
41 sys.exit(main(sys.argv))