OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import HTMLParser | 5 import HTMLParser |
6 import logging | 6 import logging |
7 import os | 7 import os |
8 import re | 8 import re |
9 import tempfile | 9 import tempfile |
10 import threading | 10 import threading |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 test_name = None | 136 test_name = None |
137 | 137 |
138 def handle_possibly_unknown_test(): | 138 def handle_possibly_unknown_test(): |
139 if test_name is not None: | 139 if test_name is not None: |
140 results.append(base_test_result.BaseTestResult( | 140 results.append(base_test_result.BaseTestResult( |
141 TestNameWithoutDisabledPrefix(test_name), | 141 TestNameWithoutDisabledPrefix(test_name), |
142 fallback_result_type or base_test_result.ResultType.UNKNOWN, | 142 fallback_result_type or base_test_result.ResultType.UNKNOWN, |
143 duration, log=('\n'.join(log) if log else ''))) | 143 duration, log=('\n'.join(log) if log else ''))) |
144 | 144 |
145 for l in output: | 145 for l in output: |
146 logging.info(l) | |
147 matcher = _RE_TEST_STATUS.match(l) | 146 matcher = _RE_TEST_STATUS.match(l) |
148 if matcher: | 147 if matcher: |
149 if matcher.group(1) == 'RUN': | 148 if matcher.group(1) == 'RUN': |
150 handle_possibly_unknown_test() | 149 handle_possibly_unknown_test() |
151 duration = 0 | 150 duration = 0 |
152 fallback_result_type = None | 151 fallback_result_type = None |
153 log = [] | 152 log = [] |
154 result_type = None | 153 result_type = None |
155 elif matcher.group(1) == 'OK': | 154 elif matcher.group(1) == 'OK': |
156 result_type = base_test_result.ResultType.PASS | 155 result_type = base_test_result.ResultType.PASS |
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
505 '%s' % l for l in (line.strip() for line in disabled_tests_file) | 504 '%s' % l for l in (line.strip() for line in disabled_tests_file) |
506 if l and not l.startswith('#')] | 505 if l and not l.startswith('#')] |
507 | 506 |
508 return '*-%s' % ':'.join(disabled_filter_items) | 507 return '*-%s' % ':'.join(disabled_filter_items) |
509 | 508 |
510 #override | 509 #override |
511 def TearDown(self): | 510 def TearDown(self): |
512 """Do nothing.""" | 511 """Do nothing.""" |
513 pass | 512 pass |
514 | 513 |
OLD | NEW |