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

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

Issue 189133005: Rename chromium_testshell target to chrome_shell_apk. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 9 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 | Annotate | Revision Log
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 collections 9 import collections
10 import logging 10 import logging
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 else: 203 else:
204 options.exclude_annotations = [] 204 options.exclude_annotations = []
205 205
206 206
207 def AddInstrumentationTestOptions(option_parser): 207 def AddInstrumentationTestOptions(option_parser):
208 """Adds Instrumentation test options to |option_parser|.""" 208 """Adds Instrumentation test options to |option_parser|."""
209 209
210 option_parser.usage = '%prog instrumentation [options]' 210 option_parser.usage = '%prog instrumentation [options]'
211 option_parser.commands_dict = {} 211 option_parser.commands_dict = {}
212 option_parser.example = ('%prog instrumentation ' 212 option_parser.example = ('%prog instrumentation '
213 '--test-apk=ChromiumTestShellTest') 213 '--test-apk=ChromeShellTest')
214 214
215 AddJavaTestOptions(option_parser) 215 AddJavaTestOptions(option_parser)
216 AddCommonOptions(option_parser) 216 AddCommonOptions(option_parser)
217 217
218 option_parser.add_option('-j', '--java-only', action='store_true', 218 option_parser.add_option('-j', '--java-only', action='store_true',
219 default=False, help='Run only the Java tests.') 219 default=False, help='Run only the Java tests.')
220 option_parser.add_option('-p', '--python-only', action='store_true', 220 option_parser.add_option('-p', '--python-only', action='store_true',
221 default=False, 221 default=False,
222 help='Run only the host-driven tests.') 222 help='Run only the host-driven tests.')
223 option_parser.add_option('--host-driven-root', 223 option_parser.add_option('--host-driven-root',
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 options.test_apk_path, 289 options.test_apk_path,
290 options.test_apk_jar_path) 290 options.test_apk_jar_path)
291 291
292 292
293 def AddUIAutomatorTestOptions(option_parser): 293 def AddUIAutomatorTestOptions(option_parser):
294 """Adds UI Automator test options to |option_parser|.""" 294 """Adds UI Automator test options to |option_parser|."""
295 295
296 option_parser.usage = '%prog uiautomator [options]' 296 option_parser.usage = '%prog uiautomator [options]'
297 option_parser.commands_dict = {} 297 option_parser.commands_dict = {}
298 option_parser.example = ( 298 option_parser.example = (
299 '%prog uiautomator --test-jar=chromium_testshell_uiautomator_tests' 299 '%prog uiautomator --test-jar=chrome_shell_uiautomator_tests'
300 ' --package=chromium_test_shell') 300 ' --package=chrome_shell')
301 option_parser.add_option( 301 option_parser.add_option(
302 '--package', 302 '--package',
303 help=('Package under test. Possible values: %s' % 303 help=('Package under test. Possible values: %s' %
304 constants.PACKAGE_INFO.keys())) 304 constants.PACKAGE_INFO.keys()))
305 option_parser.add_option( 305 option_parser.add_option(
306 '--test-jar', dest='test_jar', 306 '--test-jar', dest='test_jar',
307 help=('The name of the dexed jar containing the tests (without the ' 307 help=('The name of the dexed jar containing the tests (without the '
308 '.dex.jar extension). Alternatively, this can be a full path ' 308 '.dex.jar extension). Alternatively, this can be a full path '
309 'to the jar.')) 309 'to the jar.'))
310 310
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
361 options.uiautomator_info_jar, 361 options.uiautomator_info_jar,
362 options.package) 362 options.package)
363 363
364 364
365 def AddMonkeyTestOptions(option_parser): 365 def AddMonkeyTestOptions(option_parser):
366 """Adds monkey test options to |option_parser|.""" 366 """Adds monkey test options to |option_parser|."""
367 367
368 option_parser.usage = '%prog monkey [options]' 368 option_parser.usage = '%prog monkey [options]'
369 option_parser.commands_dict = {} 369 option_parser.commands_dict = {}
370 option_parser.example = ( 370 option_parser.example = (
371 '%prog monkey --package=chromium_test_shell') 371 '%prog monkey --package=chrome_shell')
372 372
373 option_parser.add_option( 373 option_parser.add_option(
374 '--package', 374 '--package',
375 help=('Package under test. Possible values: %s' % 375 help=('Package under test. Possible values: %s' %
376 constants.PACKAGE_INFO.keys())) 376 constants.PACKAGE_INFO.keys()))
377 option_parser.add_option( 377 option_parser.add_option(
378 '--event-count', default=10000, type='int', 378 '--event-count', default=10000, type='int',
379 help='Number of events to generate [default: %default].') 379 help='Number of events to generate [default: %default].')
380 option_parser.add_option( 380 option_parser.add_option(
381 '--category', default='', 381 '--category', default='',
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
800 800
801 def main(argv): 801 def main(argv):
802 signal.signal(signal.SIGUSR1, DumpThreadStacks) 802 signal.signal(signal.SIGUSR1, DumpThreadStacks)
803 option_parser = command_option_parser.CommandOptionParser( 803 option_parser = command_option_parser.CommandOptionParser(
804 commands_dict=VALID_COMMANDS) 804 commands_dict=VALID_COMMANDS)
805 return command_option_parser.ParseAndExecute(option_parser) 805 return command_option_parser.ParseAndExecute(option_parser)
806 806
807 807
808 if __name__ == '__main__': 808 if __name__ == '__main__':
809 sys.exit(main(sys.argv)) 809 sys.exit(main(sys.argv))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698