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

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

Issue 2968003003: Stop silently accepting unsupported flags in test binaries (Closed)
Patch Set: Ignore flags passed by xcodebuild 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
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 parser.add_argument('--no-sandbox', action='store_true', default=False)
86
84 # We have to do this, since --isolated-script-test-output is passed as an 87 # 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 88 # argument to the executable by the swarming scripts, and we want to pass it
86 # to gtest-parallel instead. 89 # to gtest-parallel instead.
87 options, executable_args = parser.parse_known_args(executable_args) 90 options, executable_args = parser.parse_known_args(executable_args)
88 91
89 # --isolated-script-test-output is used to upload results to the flakiness 92 # --isolated-script-test-output is used to upload results to the flakiness
90 # dashboard. This translation is made because gtest-parallel expects the flag 93 # dashboard. This translation is made because gtest-parallel expects the flag
91 # to be called --dump_json_test_results instead. 94 # to be called --dump_json_test_results instead.
92 if options.isolated_script_test_output: 95 if options.isolated_script_test_output:
93 gtest_parallel_args += [ 96 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)] 148 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) 149 log_file = os.path.join(output_dir, '%s-tests.log' % test_status)
147 CatFiles(logs, log_file) 150 CatFiles(logs, log_file)
148 os.rmdir(logs_dir) 151 os.rmdir(logs_dir)
149 152
150 return exit_code 153 return exit_code
151 154
152 155
153 if __name__ == '__main__': 156 if __name__ == '__main__':
154 sys.exit(main()) 157 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | tools_webrtc/valgrind/webrtc_tests.py » ('j') | tools_webrtc/valgrind/webrtc_tests.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698