2010-12-02 Sam Weinig <sam@webkit.org>
[WebKit.git] / WebKitTools / Scripts / webkitpy / layout_tests / layout_package / dump_render_tree_thread.py
index 65d0b0912e95d88ca627eb2709d9a57560ddbfbf..880cc60a882ccbf6325c212ef4900c5d9ec14fd3 100644 (file)
@@ -98,7 +98,7 @@ class WatchableThread(threading.Thread):
 
 
 class TestShellThread(WatchableThread):
 
 
 class TestShellThread(WatchableThread):
-    def __init__(self, port, options, worker_number, worker_name,
+    def __init__(self, port, options, worker_number,
                  filename_list_queue, result_queue):
         """Initialize all the local state for this DumpRenderTree thread.
 
                  filename_list_queue, result_queue):
         """Initialize all the local state for this DumpRenderTree thread.
 
@@ -106,7 +106,6 @@ class TestShellThread(WatchableThread):
           port: interface to port-specific hooks
           options: command line options argument from optparse
           worker_number: identifier for a particular worker thread.
           port: interface to port-specific hooks
           options: command line options argument from optparse
           worker_number: identifier for a particular worker thread.
-          worker_name: for logging.
           filename_list_queue: A thread safe Queue class that contains lists
               of tuples of (filename, uri) pairs.
           result_queue: A thread safe Queue class that will contain
           filename_list_queue: A thread safe Queue class that contains lists
               of tuples of (filename, uri) pairs.
           result_queue: A thread safe Queue class that will contain
@@ -116,7 +115,7 @@ class TestShellThread(WatchableThread):
         self._port = port
         self._options = options
         self._worker_number = worker_number
         self._port = port
         self._options = options
         self._worker_number = worker_number
-        self._name = worker_name
+        self._name = 'worker/%d' % worker_number
         self._filename_list_queue = filename_list_queue
         self._result_queue = result_queue
 
         self._filename_list_queue = filename_list_queue
         self._result_queue = result_queue
 
@@ -184,6 +183,9 @@ class TestShellThread(WatchableThread):
     def get_num_tests(self):
         return self._num_tests
 
     def get_num_tests(self):
         return self._num_tests
 
+    def name(self):
+        return self._name
+
     def next_timeout(self):
         """Return the time the test is supposed to finish by."""
         if self._next_timeout:
     def next_timeout(self):
         """Return the time the test is supposed to finish by."""
         if self._next_timeout:
@@ -333,7 +335,7 @@ class TestShellThread(WatchableThread):
 
         class SingleTestThread(threading.Thread):
             def run(self):
 
         class SingleTestThread(threading.Thread):
             def run(self):
-                result = worker._run_single_test(driver, test_input)
+                result = worker._run_single_test(test_input, driver)
 
         thread = SingleTestThread()
         thread.start()
 
         thread = SingleTestThread()
         thread.start()