- Revision
- 209279
- Author
- [email protected]
- Date
- 2016-12-02 15:07:41 -0800 (Fri, 02 Dec 2016)
Log Message
[CSS Parser] Fix errors in numerous layout tests
https://bugs.webkit.org/show_bug.cgi?id=165343
Reviewed by Zalan Bujtas.
* fast/backgrounds/repeat/parsing-background-repeat-expected.txt:
* fast/backgrounds/repeat/script-tests/parsing-background-repeat.js:
The old parser partially applies shorthands, even if it rejects later on.
The new parser properly rejects the entire shorthand. Fix the test so that
the numbers at the end are not unitless so that the entire shorthand parses, allowing
the components to be obtained.
* fast/css/unknown-pseudo-element-matching-expected.txt:
* fast/css/unknown-pseudo-element-matching.html:
* fast/text/crash-complex-text-surrogate.html:
The old parser allows the tag name to be omitted following a namespace bar (|). This
is not legal according to the namespaces spec, and the new parser behaves correctly.
For the crash test, it's important that all the code still runs, so we know the crash
doesn't happen, so I patched the test to put in '*' for the tag names to keep everything
the same.
For the unknown-pseudo-element test, I just removed the five invalid cases.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (209278 => 209279)
--- trunk/LayoutTests/ChangeLog 2016-12-02 23:07:25 UTC (rev 209278)
+++ trunk/LayoutTests/ChangeLog 2016-12-02 23:07:41 UTC (rev 209279)
@@ -1,5 +1,30 @@
2016-12-02 Dave Hyatt <[email protected]>
+ [CSS Parser] Fix errors in numerous layout tests
+ https://bugs.webkit.org/show_bug.cgi?id=165343
+
+ Reviewed by Zalan Bujtas.
+
+ * fast/backgrounds/repeat/parsing-background-repeat-expected.txt:
+ * fast/backgrounds/repeat/script-tests/parsing-background-repeat.js:
+ The old parser partially applies shorthands, even if it rejects later on.
+ The new parser properly rejects the entire shorthand. Fix the test so that
+ the numbers at the end are not unitless so that the entire shorthand parses, allowing
+ the components to be obtained.
+
+ * fast/css/unknown-pseudo-element-matching-expected.txt:
+ * fast/css/unknown-pseudo-element-matching.html:
+ * fast/text/crash-complex-text-surrogate.html:
+ The old parser allows the tag name to be omitted following a namespace bar (|). This
+ is not legal according to the namespaces spec, and the new parser behaves correctly.
+ For the crash test, it's important that all the code still runs, so we know the crash
+ doesn't happen, so I patched the test to put in '*' for the tag names to keep everything
+ the same.
+
+ For the unknown-pseudo-element test, I just removed the five invalid cases.
+
+2016-12-02 Dave Hyatt <[email protected]>
+
[CSS Parser] Turn off the large value test, since clamping is not the same.
https://bugs.webkit.org/show_bug.cgi?id=165341
Modified: trunk/LayoutTests/fast/backgrounds/repeat/parsing-background-repeat-expected.txt (209278 => 209279)
--- trunk/LayoutTests/fast/backgrounds/repeat/parsing-background-repeat-expected.txt 2016-12-02 23:07:25 UTC (rev 209278)
+++ trunk/LayoutTests/fast/backgrounds/repeat/parsing-background-repeat-expected.txt 2016-12-02 23:07:41 UTC (rev 209279)
@@ -17,8 +17,8 @@
PASS test("background: purple url(resources/gradient.gif) repeat-y 50% 50%") is "repeat-y"
PASS test("background: purple url(resources/gradient.gif) repeat center") is "repeat"
PASS test("background: purple url(resources/gradient.gif) no-repeat 12px") is "no-repeat"
-PASS test("background: purple url(resources/gradient.gif) round left 50") is "round"
-PASS test("background: purple url(resources/gradient.gif) space 25 25") is "space"
+PASS test("background: purple url(resources/gradient.gif) round left 50px") is "round"
+PASS test("background: purple url(resources/gradient.gif) space 25px 25px") is "space"
PASS test("background-repeat: 45;") is ""
PASS test("background-repeat: coconut;") is ""
PASS successfullyParsed is true
Modified: trunk/LayoutTests/fast/backgrounds/repeat/script-tests/parsing-background-repeat.js (209278 => 209279)
--- trunk/LayoutTests/fast/backgrounds/repeat/script-tests/parsing-background-repeat.js 2016-12-02 23:07:25 UTC (rev 209278)
+++ trunk/LayoutTests/fast/backgrounds/repeat/script-tests/parsing-background-repeat.js 2016-12-02 23:07:41 UTC (rev 209279)
@@ -27,8 +27,8 @@
shouldBe('test("background: purple url(resources/gradient.gif) repeat-y 50% 50%")', '"repeat-y"');
shouldBe('test("background: purple url(resources/gradient.gif) repeat center")', '"repeat"');
shouldBe('test("background: purple url(resources/gradient.gif) no-repeat 12px")', '"no-repeat"');
-shouldBe('test("background: purple url(resources/gradient.gif) round left 50")', '"round"');
-shouldBe('test("background: purple url(resources/gradient.gif) space 25 25")', '"space"');
+shouldBe('test("background: purple url(resources/gradient.gif) round left 50px")', '"round"');
+shouldBe('test("background: purple url(resources/gradient.gif) space 25px 25px")', '"space"');
shouldBe('test("background-repeat: 45;")', '""');
shouldBe('test("background-repeat: coconut;")', '""');
Modified: trunk/LayoutTests/fast/css/unknown-pseudo-element-matching-expected.txt (209278 => 209279)
--- trunk/LayoutTests/fast/css/unknown-pseudo-element-matching-expected.txt 2016-12-02 23:07:25 UTC (rev 209278)
+++ trunk/LayoutTests/fast/css/unknown-pseudo-element-matching-expected.txt 2016-12-02 23:07:41 UTC (rev 209279)
@@ -4,17 +4,12 @@
::-webkit-slider-thumb should match: PASS
*::-webkit-slider-thumb should match: PASS
::-webkit-slider-thumb, where HTML is not default namespace should not match: PASS
-*|::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
*|*::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
-html|::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
html|*::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
#foo::-webkit-slider-thumb should match: PASS
.bar::-webkit-slider-thumb should match: PASS
#foo::-webkit-slider-thumb, where HTML is not default namespace should not match: PASS
.bar::-webkit-slider-thumb, where HTML is not default namespace should not match: PASS
-html|#foo::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
-html|.bar::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
-*|#foo::-webkit-slider-thumb, where HTML is not default namespace should match: PASS
input::-webkit-slider-thumb should match: PASS
input#foo::-webkit-slider-thumb should match: PASS
input.bar::-webkit-slider-thumb should match: PASS
Modified: trunk/LayoutTests/fast/css/unknown-pseudo-element-matching.html (209278 => 209279)
--- trunk/LayoutTests/fast/css/unknown-pseudo-element-matching.html 2016-12-02 23:07:25 UTC (rev 209278)
+++ trunk/LayoutTests/fast/css/unknown-pseudo-element-matching.html 2016-12-02 23:07:41 UTC (rev 209279)
@@ -75,17 +75,12 @@
runSelectorTest(MATCH, '::-webkit-slider-thumb');
runSelectorTest(MATCH, '*::-webkit-slider-thumb');
runSelectorTest(NO_MATCH, '::-webkit-slider-thumb', WITH_NAMESPACES);
- runSelectorTest(MATCH, '*|::-webkit-slider-thumb', WITH_NAMESPACES);
runSelectorTest(MATCH, '*|*::-webkit-slider-thumb', WITH_NAMESPACES);
- runSelectorTest(MATCH, 'html|::-webkit-slider-thumb', WITH_NAMESPACES);
runSelectorTest(MATCH, 'html|*::-webkit-slider-thumb', WITH_NAMESPACES);
runSelectorTest(MATCH, '#foo::-webkit-slider-thumb');
runSelectorTest(MATCH, '.bar::-webkit-slider-thumb');
runSelectorTest(NO_MATCH, '#foo::-webkit-slider-thumb', WITH_NAMESPACES);
runSelectorTest(NO_MATCH, '.bar::-webkit-slider-thumb', WITH_NAMESPACES);
- runSelectorTest(MATCH, 'html|#foo::-webkit-slider-thumb', WITH_NAMESPACES);
- runSelectorTest(MATCH, 'html|.bar::-webkit-slider-thumb', WITH_NAMESPACES);
- runSelectorTest(MATCH, '*|#foo::-webkit-slider-thumb', WITH_NAMESPACES);
runSelectorTest(MATCH, 'input::-webkit-slider-thumb');
runSelectorTest(MATCH, 'input#foo::-webkit-slider-thumb');
runSelectorTest(MATCH, 'input.bar::-webkit-slider-thumb');
Modified: trunk/LayoutTests/fast/text/crash-complex-text-surrogate.html (209278 => 209279)
--- trunk/LayoutTests/fast/text/crash-complex-text-surrogate.html 2016-12-02 23:07:25 UTC (rev 209278)
+++ trunk/LayoutTests/fast/text/crash-complex-text-surrogate.html 2016-12-02 23:07:41 UTC (rev 209279)
@@ -75,7 +75,7 @@
try {
var scroll_81 = document.createElement("bdo");
scroll_81.setAttribute("id", "webtest8");
-document.querySelector("plaintext:first-of-type ~ *|:out-of-range").insertBefore(scroll_81, document.querySelector("plaintext:first-of-type ~ *|:out-of-range").childNodes[9]);
+document.querySelector("plaintext:first-of-type ~ *|*:out-of-range").insertBefore(scroll_81, document.querySelector("plaintext:first-of-type ~ *|*:out-of-range").childNodes[9]);
scroll_81.setAttribute("style", "overflow: scroll");
scroll_81.scrollLeft = 0;
scroll_81.scrolltop = 0xffffffff;