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

Side by Side Diff: tools_webrtc/gtest-parallel-wrapper.py

Issue 2968003003: Stop silently accepting unsupported flags in test binaries (Closed)
Patch Set: Add TODO Created 3 years, 4 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 | « no previous file | tools_webrtc/valgrind/webrtc_tests.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 (c) 2016 The WebRTC project authors. All Rights Reserved. 3 # Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
4 # 4 #
5 # Use of this source code is governed by a BSD-style license 5 # Use of this source code is governed by a BSD-style license
6 # that can be found in the LICENSE file in the root of the source 6 # that can be found in the LICENSE file in the root of the source
7 # tree. An additional intellectual property rights grant can be found 7 # tree. An additional intellectual property rights grant can be found
8 # in the file PATENTS. All contributing project authors may 8 # in the file PATENTS. All contributing project authors may
9 # be found in the AUTHORS file in the root of the source tree. 9 # be found in the AUTHORS file in the root of the source tree.
10 10
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 74
75 parser = argparse.ArgumentParser() 75 parser = argparse.ArgumentParser()
76 parser.add_argument('--isolated-script-test-output', type=str, default=None) 76 parser.add_argument('--isolated-script-test-output', type=str, default=None)
77 77
78 # We don't need to implement this flag, and possibly can't, since it's 78 # We don't need to implement this flag, and possibly can't, since it's
79 # intended for results of Telemetry tests. See 79 # intended for results of Telemetry tests. See
80 # https://chromium.googlesource.com/external/github.com/catapult-project/catap ult/+/HEAD/dashboard/docs/data-format.md 80 # https://chromium.googlesource.com/external/github.com/catapult-project/catap ult/+/HEAD/dashboard/docs/data-format.md
81 parser.add_argument('--isolated-script-test-chartjson-output', type=str, 81 parser.add_argument('--isolated-script-test-chartjson-output', type=str,
82 default=None) 82 default=None)
83 83
84 # No-sandbox is a Chromium-specific flag, ignore it.
85 # TODO(oprypin): Remove (bugs.webrtc.org/8115)
86 parser.add_argument('--no-sandbox', action='store_true', default=False)
87
84 # We have to do this, since --isolated-script-test-output is passed as an 88 # We have to do this, since --isolated-script-test-output is passed as an
85 # argument to the executable by the swarming scripts, and we want to pass it 89 # argument to the executable by the swarming scripts, and we want to pass it
86 # to gtest-parallel instead. 90 # to gtest-parallel instead.
87 options, executable_args = parser.parse_known_args(executable_args) 91 options, executable_args = parser.parse_known_args(executable_args)
88 92
89 # --isolated-script-test-output is used to upload results to the flakiness 93 # --isolated-script-test-output is used to upload results to the flakiness
90 # dashboard. This translation is made because gtest-parallel expects the flag 94 # dashboard. This translation is made because gtest-parallel expects the flag
91 # to be called --dump_json_test_results instead. 95 # to be called --dump_json_test_results instead.
92 if options.isolated_script_test_output: 96 if options.isolated_script_test_output:
93 gtest_parallel_args += [ 97 gtest_parallel_args += [
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 logs = [os.path.join(logs_dir, log) for log in os.listdir(logs_dir)] 149 logs = [os.path.join(logs_dir, log) for log in os.listdir(logs_dir)]
146 log_file = os.path.join(output_dir, '%s-tests.log' % test_status) 150 log_file = os.path.join(output_dir, '%s-tests.log' % test_status)
147 CatFiles(logs, log_file) 151 CatFiles(logs, log_file)
148 os.rmdir(logs_dir) 152 os.rmdir(logs_dir)
149 153
150 return exit_code 154 return exit_code
151 155
152 156
153 if __name__ == '__main__': 157 if __name__ == '__main__':
154 sys.exit(main()) 158 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | tools_webrtc/valgrind/webrtc_tests.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698