OLD | NEW |
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 Loading... |
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 | |
88 # We have to do this, since --isolated-script-test-output is passed as an | 84 # We have to do this, since --isolated-script-test-output is passed as an |
89 # argument to the executable by the swarming scripts, and we want to pass it | 85 # argument to the executable by the swarming scripts, and we want to pass it |
90 # to gtest-parallel instead. | 86 # to gtest-parallel instead. |
91 options, executable_args = parser.parse_known_args(executable_args) | 87 options, executable_args = parser.parse_known_args(executable_args) |
92 | 88 |
93 # --isolated-script-test-output is used to upload results to the flakiness | 89 # --isolated-script-test-output is used to upload results to the flakiness |
94 # dashboard. This translation is made because gtest-parallel expects the flag | 90 # dashboard. This translation is made because gtest-parallel expects the flag |
95 # to be called --dump_json_test_results instead. | 91 # to be called --dump_json_test_results instead. |
96 if options.isolated_script_test_output: | 92 if options.isolated_script_test_output: |
97 gtest_parallel_args += [ | 93 gtest_parallel_args += [ |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
149 logs = [os.path.join(logs_dir, log) for log in os.listdir(logs_dir)] | 145 logs = [os.path.join(logs_dir, log) for log in os.listdir(logs_dir)] |
150 log_file = os.path.join(output_dir, '%s-tests.log' % test_status) | 146 log_file = os.path.join(output_dir, '%s-tests.log' % test_status) |
151 CatFiles(logs, log_file) | 147 CatFiles(logs, log_file) |
152 os.rmdir(logs_dir) | 148 os.rmdir(logs_dir) |
153 | 149 |
154 return exit_code | 150 return exit_code |
155 | 151 |
156 | 152 |
157 if __name__ == '__main__': | 153 if __name__ == '__main__': |
158 sys.exit(main()) | 154 sys.exit(main()) |
OLD | NEW |