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

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

Issue 2130863002: Check environment (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Delete unnecessary line breaks. Created 4 years, 5 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/local/device/local_device_environment.py ('k') | tools/mb/mb.py » ('j') | 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 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 group.add_argument('-e', '--environment', default='local', 97 group.add_argument('-e', '--environment', default='local',
98 choices=constants.VALID_ENVIRONMENTS, 98 choices=constants.VALID_ENVIRONMENTS,
99 help='Test environment to run in (default: %(default)s).') 99 help='Test environment to run in (default: %(default)s).')
100 group.add_argument('--adb-path', type=os.path.abspath, 100 group.add_argument('--adb-path', type=os.path.abspath,
101 help=('Specify the absolute path of the adb binary that ' 101 help=('Specify the absolute path of the adb binary that '
102 'should be used.')) 102 'should be used.'))
103 group.add_argument('--json-results-file', '--test-launcher-summary-output', 103 group.add_argument('--json-results-file', '--test-launcher-summary-output',
104 dest='json_results_file', 104 dest='json_results_file',
105 help='If set, will dump results in JSON form ' 105 help='If set, will dump results in JSON form '
106 'to specified file.') 106 'to specified file.')
107 group.add_argument('--logdog-file',
108 help='Specifies the location for the unified logcat '
109 'file which logdog will stream.')
107 110
108 logcat_output_group = group.add_mutually_exclusive_group() 111 logcat_output_group = group.add_mutually_exclusive_group()
109 logcat_output_group.add_argument( 112 logcat_output_group.add_argument(
110 '--logcat-output-dir', 113 '--logcat-output-dir',
111 help='If set, will dump logcats recorded during test run to directory. ' 114 help='If set, will dump logcats recorded during test run to directory. '
112 'File names will be the device ids with timestamps.') 115 'File names will be the device ids with timestamps.')
113 logcat_output_group.add_argument( 116 logcat_output_group.add_argument(
114 '--logcat-output-file', 117 '--logcat-output-file',
115 help='If set, will merge logcats recorded during test run and dump them ' 118 help='If set, will merge logcats recorded during test run and dump them '
116 'to the specified file.') 119 'to the specified file.')
(...skipping 857 matching lines...) Expand 10 before | Expand all | Expand 10 after
974 if e.is_infra_error: 977 if e.is_infra_error:
975 return constants.INFRA_EXIT_CODE 978 return constants.INFRA_EXIT_CODE
976 return constants.ERROR_EXIT_CODE 979 return constants.ERROR_EXIT_CODE
977 except: # pylint: disable=W0702 980 except: # pylint: disable=W0702
978 logging.exception('Unrecognized error occurred.') 981 logging.exception('Unrecognized error occurred.')
979 return constants.ERROR_EXIT_CODE 982 return constants.ERROR_EXIT_CODE
980 983
981 984
982 if __name__ == '__main__': 985 if __name__ == '__main__':
983 sys.exit(main()) 986 sys.exit(main())
OLDNEW
« no previous file with comments | « build/android/pylib/local/device/local_device_environment.py ('k') | tools/mb/mb.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698