Modified: trunk/Tools/ChangeLog (173534 => 173535)
--- trunk/Tools/ChangeLog 2014-09-11 20:04:38 UTC (rev 173534)
+++ trunk/Tools/ChangeLog 2014-09-11 20:38:19 UTC (rev 173535)
@@ -1,3 +1,21 @@
+2014-09-11 Rebecca Hauck <[email protected]>
+
+ webkitpy test failures from import-w3c-tests
+ https://bugs.webkit.org/show_bug.cgi?id=136752
+
+ Reviewed by Bem Jones-Bey.
+
+ This patch fixes a bug in import-w3c-tests where we were appending
+ the wrong set of files to the copy_list. This also updates the tests
+ to clear the failures introduced in the patch for bug 135929.
+
+ * Scripts/webkitpy/w3c/test_converter_unittest.py:
+ (W3CTestConverterTest.test_read_prefixed_property_list):
+ * Scripts/webkitpy/w3c/test_parser.py:
+ (TestParser.analyze_test):
+ (TestParser.support_files):
+ * Scripts/webkitpy/w3c/test_parser_unittest.py:
+
2014-09-10 Brent Fulgham <[email protected]>
Blink merge: Speculative fix for windows run-webkit-tests hangs
Modified: trunk/Tools/Scripts/webkitpy/w3c/test_converter_unittest.py (173534 => 173535)
--- trunk/Tools/Scripts/webkitpy/w3c/test_converter_unittest.py 2014-09-11 20:04:38 UTC (rev 173534)
+++ trunk/Tools/Scripts/webkitpy/w3c/test_converter_unittest.py 2014-09-11 20:38:19 UTC (rev 173535)
@@ -53,7 +53,7 @@
""" Tests that the current list of properties requiring the -webkit- prefix load correctly """
# FIXME: We should be passing in a MockHost here ...
- converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME)
+ converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None)
prop_list = converter.prefixed_properties
self.assertTrue(prop_list, 'No prefixed properties found')
@@ -78,7 +78,7 @@
</body>
</html>
"""
- converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME)
+ converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None)
oc = OutputCapture()
oc.capture_output()
@@ -100,7 +100,7 @@
</head>
"""
fake_dir_path = self.fake_dir_path("harnessonly")
- converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME)
+ converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME, None)
converter.feed(test_html)
converter.close()
converted = converter.output()
@@ -128,7 +128,7 @@
</html>
"""
fake_dir_path = self.fake_dir_path('harnessandprops')
- converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME)
+ converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME, None)
test_content = self.generate_test_content(converter.prefixed_properties, 1, test_html)
oc = OutputCapture()
@@ -165,7 +165,7 @@
</html>
"""
fake_dir_path = self.fake_dir_path('harnessandprops')
- converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME)
+ converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME, None)
oc = OutputCapture()
oc.capture_output()
@@ -191,7 +191,7 @@
</head>
"""
fake_dir_path = self.fake_dir_path('testharnesspaths')
- converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME)
+ converter = _W3CTestConverter(fake_dir_path, DUMMY_FILENAME, None)
oc = OutputCapture()
oc.capture_output()
@@ -268,7 +268,7 @@
]]></style>
</html>
"""
- converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME)
+ converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None)
test_content = self.generate_test_content(converter.prefixed_properties, 20, test_html)
oc = OutputCapture()
Modified: trunk/Tools/Scripts/webkitpy/w3c/test_parser.py (173534 => 173535)
--- trunk/Tools/Scripts/webkitpy/w3c/test_parser.py 2014-09-11 20:04:38 UTC (rev 173534)
+++ trunk/Tools/Scripts/webkitpy/w3c/test_parser.py 2014-09-11 20:38:19 UTC (rev 173535)
@@ -73,6 +73,13 @@
test_info = None
+ if test_contents is None and self.test_doc is None:
+ return test_info
+ if test_contents is not None:
+ self.test_doc = Parser(test_contents)
+ if ref_contents is not None:
+ self.ref_doc = Parser(ref_contents)
+
# First check if it's a reftest
matches = self.reference_links_of_type('match') + self.reference_links_of_type('mismatch')
if matches:
@@ -139,7 +146,7 @@
paths = src_paths + href_paths + urls
for path in paths:
uri_scheme_pattern = re.compile(r"[A-Za-z][A-Za-z+.-]*:")
- if uri_scheme_pattern.match(path):
+ if not uri_scheme_pattern.match(path):
support_files.append(path)
return support_files
Modified: trunk/Tools/Scripts/webkitpy/w3c/test_parser_unittest.py (173534 => 173535)
--- trunk/Tools/Scripts/webkitpy/w3c/test_parser_unittest.py 2014-09-11 20:04:38 UTC (rev 173534)
+++ trunk/Tools/Scripts/webkitpy/w3c/test_parser_unittest.py 2014-09-11 20:38:19 UTC (rev 173535)
@@ -133,8 +133,8 @@
self.assertTrue('test' in test_info.keys(), 'did not find a test file')
self.assertTrue('reference' in test_info.keys(), 'did not find a reference file')
self.assertTrue(test_info['reference'].startswith(test_path), 'reference path is not correct')
- self.assertTrue('refsupport' in test_info.keys(), 'there should be refsupport files for this test')
- self.assertEquals(len(test_info['refsupport']), 3, 'there should be 3 support files in this reference')
+ self.assertTrue('reference_support_info' in test_info.keys(), 'there should be reference_support_info for this test')
+ self.assertEquals(len(test_info['reference_support_info']['files']), 3, 'there should be 3 support files in this reference')
self.assertFalse('jstest' in test_info.keys(), 'test should not have been analyzed as a jstest')
def test_analyze_jstest(self):