| OLD | NEW |
| (Empty) |
| 1 #!/usr/bin/env python | |
| 2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | |
| 3 # Use of this source code is governed by a BSD-style license that can be | |
| 4 # found in the LICENSE file. | |
| 5 | |
| 6 """ Run the WebKit tests. """ | |
| 7 | |
| 8 from build_step import BuildStep, BuildStepWarning | |
| 9 from py.utils import shell_utils | |
| 10 import os | |
| 11 import sys | |
| 12 | |
| 13 | |
| 14 class ChromeDRTCanaryRunWebkitTests(BuildStep): | |
| 15 def __init__(self, timeout=16800, no_output_timeout=16800, **kwargs): | |
| 16 super(ChromeDRTCanaryRunWebkitTests, self).__init__( | |
| 17 timeout=timeout, no_output_timeout=no_output_timeout, **kwargs) | |
| 18 | |
| 19 def _Run(self): | |
| 20 test_script_path = os.path.join('webkit', 'tools', 'layout_tests', | |
| 21 'run_webkit_tests.sh') | |
| 22 cmd = [ | |
| 23 test_script_path, '--build-directory', 'out', '--nocheck-sys-deps', | |
| 24 '--additional-platform-directory=%s' % | |
| 25 self._flavor_utils.baseline_dir, | |
| 26 '--no-show-results' | |
| 27 ] | |
| 28 if 'new_baseline' in self._args: | |
| 29 cmd.append('--new-baseline') | |
| 30 if self._configuration == 'Debug': | |
| 31 cmd.append('--debug') | |
| 32 if 'write_results' in self._args: | |
| 33 cmd.append('--results-directory=%s' % self._flavor_utils.result_dir) | |
| 34 try: | |
| 35 shell_utils.run(cmd) | |
| 36 except Exception as e: | |
| 37 # Allow this step to fail with a warning, since we expect to see a lot of | |
| 38 # failures which aren't our fault. Instead, we care about the diffs. | |
| 39 raise BuildStepWarning(e) | |
| 40 | |
| 41 | |
| 42 if '__main__' == __name__: | |
| 43 sys.exit(BuildStep.RunBuildStep(ChromeDRTCanaryRunWebkitTests)) | |
| OLD | NEW |