diff options
Diffstat (limited to 'WebKitTools/Scripts/webkitpy/layout_tests/port/webkit.py')
-rw-r--r-- | WebKitTools/Scripts/webkitpy/layout_tests/port/webkit.py | 30 |
1 files changed, 11 insertions, 19 deletions
diff --git a/WebKitTools/Scripts/webkitpy/layout_tests/port/webkit.py b/WebKitTools/Scripts/webkitpy/layout_tests/port/webkit.py index 0b324f5..06797c6 100644 --- a/WebKitTools/Scripts/webkitpy/layout_tests/port/webkit.py +++ b/WebKitTools/Scripts/webkitpy/layout_tests/port/webkit.py @@ -49,6 +49,7 @@ import shutil from webkitpy.common.system.executive import Executive import webkitpy.common.system.ospath as ospath +import webkitpy.layout_tests.layout_package.test_output as test_output import webkitpy.layout_tests.port.base as base import webkitpy.layout_tests.port.server_process as server_process @@ -81,14 +82,8 @@ class WebKitPort(base.Port): return '' def _build_driver(self): - exit_code = self._executive.run_command([ - self.script_path("build-dumprendertree"), - self.flag_from_configuration(self.get_option('configuration')), - ], return_exit_code=True) - if exit_code != 0: - _log.error("Failed to build DumpRenderTree") - return False - return True + configuration = self.get_option('configuration') + return self._config.build_dumprendertree(configuration) def _check_driver(self): driver_path = self._path_to_driver() @@ -357,8 +352,8 @@ class WebKitPort(base.Port): 'mac-tiger', 'mac-leopard', 'mac-snowleopard') def _build_path(self, *comps): - build_root = self._webkit_configuration_build_directory() - return os.path.join(build_root, *comps) + return self._filesystem.join(self._config.build_directory( + self.get_option('configuration')), *comps) def _path_to_driver(self): return self._build_path('DumpRenderTree') @@ -448,6 +443,7 @@ class WebKitDriver(base.Driver): command += "'" + image_hash command += "\n" + start_time = time.time() self._server_process.write(command) have_seen_content_type = False @@ -492,10 +488,6 @@ class WebKitDriver(base.Driver): timeout = deadline - time.time() line = self._server_process.read_line(timeout) - if self._image_path and len(self._image_path): - with open(self._image_path, "wb") as image_file: - image_file.write(image) - error_lines = self._server_process.error.splitlines() # FIXME: This is a hack. It is unclear why sometimes # we do not get any error lines from the server_process @@ -506,11 +498,11 @@ class WebKitDriver(base.Driver): # FIXME: This seems like the wrong section of code to be doing # this reset in. self._server_process.error = "" - return (self._server_process.crashed, - self._server_process.timed_out, - actual_image_hash, - output, - error) + return test_output.TestOutput(output, image, actual_image_hash, + self._server_process.crashed, + time.time() - start_time, + self._server_process.timed_out, + error) def stop(self): if self._server_process: |