Chromium Code Reviews| Index: tools-webrtc/gtest-parallel-wrapper.py |
| diff --git a/tools-webrtc/gtest-parallel-wrapper.py b/tools-webrtc/gtest-parallel-wrapper.py |
| index bfdef096d5b7740e9539028ffb812a0d6d4d8696..eb858a9fbf661bfdb5c245cb2c7b1b1282cead31 100755 |
| --- a/tools-webrtc/gtest-parallel-wrapper.py |
| +++ b/tools-webrtc/gtest-parallel-wrapper.py |
| @@ -65,6 +65,9 @@ def main(): |
| parser.add_argument('--isolated-script-test-chartjson-output', type=str, |
|
ehmaldonado_webrtc
2017/04/28 10:32:39
Not related to this CL, but I think we don't need
kjellander_webrtc
2017/04/28 10:59:38
I see, can you update the comment to mention the a
|
| default=None) |
| + # TODO(ehmaldonado): Figure out a way to avoid duplicating the flags in |
| + # gtest-parallel. |
| + parser.add_argument('--gtest_color', type=str, default='yes') |
|
kjellander_webrtc
2017/04/28 10:59:38
What about having 'auto' as the default, since it
|
| parser.add_argument('--output_dir', type=str, default=None) |
| parser.add_argument('--timeout', type=int, default=None) |
| @@ -89,6 +92,8 @@ def main(): |
| gtest_total_shards, |
| '--shard_index', |
| gtest_shard_index, |
| + '--gtest_color', |
| + options.gtest_color, |
| ] |
| # --isolated-script-test-output is used to upload results to the flakiness |
| @@ -122,14 +127,15 @@ def main(): |
| exit_code = subprocess.call(command, env=test_env, cwd=os.getcwd()) |
| - for test_status in 'passed', 'failed', 'interrupted': |
| - logs_dir = os.path.join(options.output_dir, test_status) |
| - if not os.path.isdir(logs_dir): |
| - continue |
| - logs = [os.path.join(logs_dir, log) for log in os.listdir(logs_dir)] |
| - log_file = os.path.join(options.output_dir, '%s-tests.log' % test_status) |
| - CatFiles(logs, log_file) |
| - os.rmdir(logs_dir) |
| + if options.output_dir: |
|
kjellander_webrtc
2017/04/28 10:59:38
if this is a bugfix, can you mention it in the CL
|
| + for test_status in 'passed', 'failed', 'interrupted': |
| + logs_dir = os.path.join(options.output_dir, test_status) |
| + if not os.path.isdir(logs_dir): |
| + continue |
| + logs = [os.path.join(logs_dir, log) for log in os.listdir(logs_dir)] |
| + log_file = os.path.join(options.output_dir, '%s-tests.log' % test_status) |
| + CatFiles(logs, log_file) |
| + os.rmdir(logs_dir) |
| return exit_code |