[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 15:24:03 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 5fb3b8e51ffffe902bf67be763e42e9985fdf670
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Nov 2 20:42:48 2010 +0000

    2010-11-02  Benjamin Kalman  <kalman at google.com>
    
            Reviewed by Ojan Vafai.
    
            new-run-webkit-tests doesn't strip "LayoutTests/" from prefix, unlike old-run-webkit-tests
            https://bugs.webkit.org/show_bug.cgi?id=48794
    
            * Scripts/webkitpy/layout_tests/run_webkit_tests.py: Strip the "LayoutTests/" prefix from test argument paths.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@71160 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index 0921c62..a2e2992 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,12 @@
+2010-11-02  Benjamin Kalman  <kalman at google.com>
+
+        Reviewed by Ojan Vafai.
+
+        new-run-webkit-tests doesn't strip "LayoutTests/" from prefix, unlike old-run-webkit-tests
+        https://bugs.webkit.org/show_bug.cgi?id=48794
+
+        * Scripts/webkitpy/layout_tests/run_webkit_tests.py: Strip the "LayoutTests/" prefix from test argument paths.
+
 2010-11-02  Adam Roben  <aroben at apple.com>
 
         Skip webkitpy.layout_tests.run_webkit_tests_unittest.MainTest on Cygwin
diff --git a/WebKitTools/Scripts/webkitpy/layout_tests/run_webkit_tests.py b/WebKitTools/Scripts/webkitpy/layout_tests/run_webkit_tests.py
index d169cd8..f103bcd 100755
--- a/WebKitTools/Scripts/webkitpy/layout_tests/run_webkit_tests.py
+++ b/WebKitTools/Scripts/webkitpy/layout_tests/run_webkit_tests.py
@@ -85,6 +85,8 @@ _log = logging.getLogger("webkitpy.layout_tests.run_webkit_tests")
 # Builder base URL where we have the archived test results.
 BUILDER_BASE_URL = "http://build.chromium.org/buildbot/layout_test_results/"
 
+LAYOUT_TESTS_DIRECTORY = "LayoutTests" + os.sep
+
 TestExpectationsFile = test_expectations.TestExpectationsFile
 
 
@@ -283,12 +285,17 @@ class TestRunner:
           last_unexpected_results: list of unexpected results to retest, if any
 
         """
-        paths = [arg for arg in args if arg and arg != '']
+        paths = [self._strip_test_dir_prefix(arg) for arg in args if arg and arg != '']
         paths += last_unexpected_results
         if self._options.test_list:
             paths += read_test_files(self._options.test_list)
         self._test_files = self._port.tests(paths)
 
+    def _strip_test_dir_prefix(self, path):
+        if path.startswith(LAYOUT_TESTS_DIRECTORY):
+            return path[len(LAYOUT_TESTS_DIRECTORY):]
+        return path
+
     def lint(self):
         # Creating the expecations for each platform/configuration pair does
         # all the test list parsing and ensures it's correct syntax (e.g. no
@@ -470,9 +477,9 @@ class TestRunner:
     def _get_dir_for_test_file(self, test_file):
         """Returns the highest-level directory by which to shard the given
         test file."""
-        index = test_file.rfind(os.sep + 'LayoutTests' + os.sep)
+        index = test_file.rfind(os.sep + LAYOUT_TESTS_DIRECTORY)
 
-        test_file = test_file[index + len('LayoutTests/'):]
+        test_file = test_file[index + len(LAYOUT_TESTS_DIRECTORY):]
         test_file_parts = test_file.split(os.sep, 1)
         directory = test_file_parts[0]
         test_file = test_file_parts[1]

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list