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

Side by Side Diff: build/android/test_runner.py

Issue 872783003: Use upload test to get uirobot test id. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « build/android/pylib/remote/device/remote_device_uirobot_test_run.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2013 The Chromium Authors. All rights reserved. 3 # Copyright 2013 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """Runs all types of tests from one unified interface.""" 7 """Runs all types of tests from one unified interface."""
8 8
9 import argparse 9 import argparse
10 import collections 10 import collections
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 help='OS to have on the device.') 133 help='OS to have on the device.')
134 group.add_argument('--results-path', default='', 134 group.add_argument('--results-path', default='',
135 help='File path to download results to.') 135 help='File path to download results to.')
136 group.add_argument('--api-protocol', 136 group.add_argument('--api-protocol',
137 help='HTTP protocol to use. (http or https)') 137 help='HTTP protocol to use. (http or https)')
138 group.add_argument('--api-address', help='Address to send HTTP requests.') 138 group.add_argument('--api-address', help='Address to send HTTP requests.')
139 group.add_argument('--api-port', help='Port to send HTTP requests to.') 139 group.add_argument('--api-port', help='Port to send HTTP requests to.')
140 group.add_argument('--runner-type', default='', 140 group.add_argument('--runner-type', default='',
141 help='Type of test to run as.') 141 help='Type of test to run as.')
142 group.add_argument('--runner-package', help='Package name of test.') 142 group.add_argument('--runner-package', help='Package name of test.')
143 group.add_argument('--app-under-test', help='APK to run tests on.')
144 group.add_argument('--device-type', default='Android', 143 group.add_argument('--device-type', default='Android',
145 choices=constants.VALID_DEVICE_TYPES, 144 choices=constants.VALID_DEVICE_TYPES,
146 help=('Type of device to run on. iOS or android')) 145 help=('Type of device to run on. iOS or android'))
147 146
148 api_secret_group = group.add_mutually_exclusive_group() 147 api_secret_group = group.add_mutually_exclusive_group()
149 api_secret_group.add_argument('--api-secret', default='', 148 api_secret_group.add_argument('--api-secret', default='',
150 help='API secret for remote devices.') 149 help='API secret for remote devices.')
151 api_secret_group.add_argument('--api-secret-file', default='', 150 api_secret_group.add_argument('--api-secret-file', default='',
152 help='Path to file that contains API secret.') 151 help='Path to file that contains API secret.')
153 152
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after
500 args.event_count, 499 args.event_count,
501 category, 500 category,
502 args.throttle, 501 args.throttle,
503 args.seed, 502 args.seed,
504 args.extra_args) 503 args.extra_args)
505 504
506 def AddUirobotTestOptions(parser): 505 def AddUirobotTestOptions(parser):
507 """Adds uirobot test options to |option_parser|.""" 506 """Adds uirobot test options to |option_parser|."""
508 group = parser.add_argument_group('Uirobot Test Options') 507 group = parser.add_argument_group('Uirobot Test Options')
509 508
509 group.add_argument('--app-under-test', help='APK to run tests on.')
510 group.add_argument( 510 group.add_argument(
511 '--minutes', default=5, type=int, 511 '--minutes', default=5, type=int,
512 help='Number of minutes to run uirobot test [default: %default].') 512 help='Number of minutes to run uirobot test [default: %default].')
513 513
514 AddCommonOptions(parser) 514 AddCommonOptions(parser)
515 AddDeviceOptions(parser) 515 AddDeviceOptions(parser)
516 AddRemoteDeviceOptions(parser) 516 AddRemoteDeviceOptions(parser)
517 517
518 def AddPerfTestOptions(parser): 518 def AddPerfTestOptions(parser):
519 """Adds perf test options to |parser|.""" 519 """Adds perf test options to |parser|."""
(...skipping 469 matching lines...) Expand 10 before | Expand all | Expand 10 after
989 subparser = command_parsers.add_parser( 989 subparser = command_parsers.add_parser(
990 test_type, usage='%(prog)s [options]', help=config.help_txt) 990 test_type, usage='%(prog)s [options]', help=config.help_txt)
991 config.add_options_func(subparser) 991 config.add_options_func(subparser)
992 992
993 args = parser.parse_args() 993 args = parser.parse_args()
994 return RunTestsCommand(args, parser) 994 return RunTestsCommand(args, parser)
995 995
996 996
997 if __name__ == '__main__': 997 if __name__ == '__main__':
998 sys.exit(main()) 998 sys.exit(main())
OLDNEW
« no previous file with comments | « build/android/pylib/remote/device/remote_device_uirobot_test_run.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698