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 constants | 9 from pylib import constants |
10 from pylib import pexpect | 10 from pylib import pexpect |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 timeout = 60 | 49 timeout = 60 |
50 # On a VM (e.g. chromium buildbots), this timeout is way too small. | 50 # On a VM (e.g. chromium buildbots), this timeout is way too small. |
51 if os.environ.get('BUILDBOT_SLAVENAME'): | 51 if os.environ.get('BUILDBOT_SLAVENAME'): |
52 timeout = timeout * 2 | 52 timeout = timeout * 2 |
53 | 53 |
54 self._timeout = timeout * self.tool.GetTimeoutScale() | 54 self._timeout = timeout * self.tool.GetTimeoutScale() |
55 if _TestSuiteRequiresHighPerfMode(self.test_package.suite_name): | 55 if _TestSuiteRequiresHighPerfMode(self.test_package.suite_name): |
56 self._perf_controller = perf_control.PerfControl(self.device) | 56 self._perf_controller = perf_control.PerfControl(self.device) |
57 | 57 |
58 #override | 58 #override |
59 def InstallTestPackage(self): | |
60 self.test_package.Install(self.device) | |
61 | |
62 #override | |
63 def PushDataDeps(self): | 59 def PushDataDeps(self): |
64 self.device.WaitUntilFullyBooted(timeout=20) | 60 self.device.WaitUntilFullyBooted(timeout=20) |
65 self.tool.CopyFiles() | 61 self.tool.CopyFiles() |
66 if os.path.exists(constants.ISOLATE_DEPS_DIR): | 62 if os.path.exists(constants.ISOLATE_DEPS_DIR): |
67 # TODO(frankf): linux_dumper_unittest_helper needs to be in the same dir | 63 # TODO(frankf): linux_dumper_unittest_helper needs to be in the same dir |
68 # as breakpad_unittests exe. Find a better way to do this. | 64 # as breakpad_unittests exe. Find a better way to do this. |
69 if self.test_package.suite_name == 'breakpad_unittests': | 65 if self.test_package.suite_name == 'breakpad_unittests': |
70 device_dir = constants.TEST_EXECUTABLE_DIR | 66 device_dir = constants.TEST_EXECUTABLE_DIR |
71 else: | 67 else: |
72 device_dir = self.device.GetExternalStoragePath() | 68 device_dir = self.device.GetExternalStoragePath() |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 self.tool.SetupEnvironment() | 185 self.tool.SetupEnvironment() |
190 | 186 |
191 #override | 187 #override |
192 def TearDown(self): | 188 def TearDown(self): |
193 """Cleans up the test enviroment for the test suite.""" | 189 """Cleans up the test enviroment for the test suite.""" |
194 if _TestSuiteRequiresHighPerfMode(self.test_package.suite_name): | 190 if _TestSuiteRequiresHighPerfMode(self.test_package.suite_name): |
195 self._perf_controller.RestoreOriginalPerfMode() | 191 self._perf_controller.RestoreOriginalPerfMode() |
196 self.test_package.ClearApplicationState(self.device) | 192 self.test_package.ClearApplicationState(self.device) |
197 self.tool.CleanUpEnvironment() | 193 self.tool.CleanUpEnvironment() |
198 super(TestRunner, self).TearDown() | 194 super(TestRunner, self).TearDown() |
OLD | NEW |