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 logging | 5 import logging |
6 import os | 6 import os |
7 import re | 7 import re |
8 | 8 |
9 from pylib import pexpect | 9 from pylib import pexpect |
10 from pylib.base import base_test_result | 10 from pylib.base import base_test_result |
(...skipping 18 matching lines...) Expand all Loading... |
29 def __init__(self, test_options, device, test_package): | 29 def __init__(self, test_options, device, test_package): |
30 """Single test suite attached to a single device. | 30 """Single test suite attached to a single device. |
31 | 31 |
32 Args: | 32 Args: |
33 test_options: A GTestOptions object. | 33 test_options: A GTestOptions object. |
34 device: Device to run the tests. | 34 device: Device to run the tests. |
35 test_package: An instance of TestPackage class. | 35 test_package: An instance of TestPackage class. |
36 """ | 36 """ |
37 | 37 |
38 super(TestRunner, self).__init__(device, test_options.tool, | 38 super(TestRunner, self).__init__(device, test_options.tool, |
39 test_options.push_deps, | |
40 test_options.cleanup_test_files) | 39 test_options.cleanup_test_files) |
41 | 40 |
42 self.test_package = test_package | 41 self.test_package = test_package |
43 self.test_package.tool = self.tool | 42 self.test_package.tool = self.tool |
44 self._test_arguments = test_options.test_arguments | 43 self._test_arguments = test_options.test_arguments |
45 | 44 |
46 timeout = test_options.timeout | 45 timeout = test_options.timeout |
47 if timeout == 0: | 46 if timeout == 0: |
48 timeout = 60 | 47 timeout = 60 |
49 # On a VM (e.g. chromium buildbots), this timeout is way too small. | 48 # On a VM (e.g. chromium buildbots), this timeout is way too small. |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 self.tool.SetupEnvironment() | 171 self.tool.SetupEnvironment() |
173 | 172 |
174 #override | 173 #override |
175 def TearDown(self): | 174 def TearDown(self): |
176 """Cleans up the test enviroment for the test suite.""" | 175 """Cleans up the test enviroment for the test suite.""" |
177 if _TestSuiteRequiresHighPerfMode(self.test_package.suite_name): | 176 if _TestSuiteRequiresHighPerfMode(self.test_package.suite_name): |
178 self._perf_controller.SetDefaultPerfMode() | 177 self._perf_controller.SetDefaultPerfMode() |
179 self.test_package.ClearApplicationState(self.device) | 178 self.test_package.ClearApplicationState(self.device) |
180 self.tool.CleanUpEnvironment() | 179 self.tool.CleanUpEnvironment() |
181 super(TestRunner, self).TearDown() | 180 super(TestRunner, self).TearDown() |
OLD | NEW |