OLD | NEW |
---|---|
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 glob | 5 import glob |
6 import logging | 6 import logging |
7 import os | 7 import os |
8 import sys | 8 import sys |
9 | 9 |
10 from base_test_runner import BaseTestRunner | 10 from base_test_runner import BaseTestRunner |
(...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
322 def RunTests(self): | 322 def RunTests(self): |
323 """Runs all tests (in rebaseline mode, runs each test in isolation). | 323 """Runs all tests (in rebaseline mode, runs each test in isolation). |
324 | 324 |
325 Returns: | 325 Returns: |
326 A TestResults object. | 326 A TestResults object. |
327 """ | 327 """ |
328 try: | 328 try: |
329 if self.test_package.rebaseline: | 329 if self.test_package.rebaseline: |
330 self.RebaselineTests() | 330 self.RebaselineTests() |
331 else: | 331 else: |
332 if not self._gtest_filter: | |
bulach
2012/12/12 11:38:59
yeah, I think this was done before we unified the
| |
333 self._gtest_filter = ('-' + ':'.join(self.GetDisabledTests()) + ':' + | |
334 ':'.join(['*.' + x + '*' for x in | |
335 self.test_package.GetDisabledPrefixes()])) | |
336 self.RunTestsWithFilter() | 332 self.RunTestsWithFilter() |
337 except errors.DeviceUnresponsiveError as e: | 333 except errors.DeviceUnresponsiveError as e: |
338 # Make sure this device is not attached | 334 # Make sure this device is not attached |
339 if android_commands.IsDeviceAttached(self.device): | 335 if android_commands.IsDeviceAttached(self.device): |
340 raise e | 336 raise e |
341 | 337 |
342 # Wrap the results | 338 # Wrap the results |
343 logging.warning(e) | 339 logging.warning(e) |
344 failed_tests = [] | 340 failed_tests = [] |
345 for t in self._gtest_filter.split(':'): | 341 for t in self._gtest_filter.split(':'): |
(...skipping 20 matching lines...) Expand all Loading... | |
366 self.tool.CleanUpEnvironment() | 362 self.tool.CleanUpEnvironment() |
367 if self.test_package.cleanup_test_files: | 363 if self.test_package.cleanup_test_files: |
368 self.adb.RemovePushedFiles() | 364 self.adb.RemovePushedFiles() |
369 if self.dump_debug_info: | 365 if self.dump_debug_info: |
370 self.dump_debug_info.StopRecordingLog() | 366 self.dump_debug_info.StopRecordingLog() |
371 if self._performance_test_setup: | 367 if self._performance_test_setup: |
372 self._performance_test_setup.TearDown() | 368 self._performance_test_setup.TearDown() |
373 if self.dump_debug_info: | 369 if self.dump_debug_info: |
374 self.dump_debug_info.ArchiveNewCrashFiles() | 370 self.dump_debug_info.ArchiveNewCrashFiles() |
375 super(SingleTestRunner, self).TearDown() | 371 super(SingleTestRunner, self).TearDown() |
OLD | NEW |