Title: [197669] trunk/LayoutTests
- Revision
- 197669
- Author
- [email protected]
- Date
- 2016-03-07 02:43:38 -0800 (Mon, 07 Mar 2016)
Log Message
[css-grid] Add missing test for grid-template shorthand
https://bugs.webkit.org/show_bug.cgi?id=155013
Reviewed by Sergio Villar Senin.
We support the following syntax in grid-template shorthand:
-webkit-grid-template: [foo1] 'a' 50px [foo2]
[bar1] 'b' 50px [bar2] / 100px;
But we don't have a test to check that grid-template-rows value
has the names of the same lines grouped. So it's:
[foo1] 50px [foo2 bar1] 50px [bar2];
This means that if we remove the third argument in
CSSParser::parseGridLineNames(), all the current tests are passing.
Without that argument, the value for grid-template-rows would be:
[foo1] 50px [foo2] [bar1] 50px [bar2];
Which is wrong.
This patch adds a specific test case for this which would fail
in that case.
* fast/css-grid-layout/grid-template-shorthand-get-set-expected.txt:
* fast/css-grid-layout/grid-template-shorthand-get-set.html:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (197668 => 197669)
--- trunk/LayoutTests/ChangeLog 2016-03-07 10:19:27 UTC (rev 197668)
+++ trunk/LayoutTests/ChangeLog 2016-03-07 10:43:38 UTC (rev 197669)
@@ -1,3 +1,32 @@
+2016-03-07 Manuel Rego Casasnovas <[email protected]>
+
+ [css-grid] Add missing test for grid-template shorthand
+ https://bugs.webkit.org/show_bug.cgi?id=155013
+
+ Reviewed by Sergio Villar Senin.
+
+ We support the following syntax in grid-template shorthand:
+ -webkit-grid-template: [foo1] 'a' 50px [foo2]
+ [bar1] 'b' 50px [bar2] / 100px;
+
+ But we don't have a test to check that grid-template-rows value
+ has the names of the same lines grouped. So it's:
+ [foo1] 50px [foo2 bar1] 50px [bar2];
+
+ This means that if we remove the third argument in
+ CSSParser::parseGridLineNames(), all the current tests are passing.
+
+ Without that argument, the value for grid-template-rows would be:
+ [foo1] 50px [foo2] [bar1] 50px [bar2];
+
+ Which is wrong.
+
+ This patch adds a specific test case for this which would fail
+ in that case.
+
+ * fast/css-grid-layout/grid-template-shorthand-get-set-expected.txt:
+ * fast/css-grid-layout/grid-template-shorthand-get-set.html:
+
2016-03-06 Zalan Bujtas <[email protected]>
[iOS] Some more gardening after r197627.
Modified: trunk/LayoutTests/fast/css-grid-layout/grid-template-shorthand-get-set-expected.txt (197668 => 197669)
--- trunk/LayoutTests/fast/css-grid-layout/grid-template-shorthand-get-set-expected.txt 2016-03-07 10:19:27 UTC (rev 197668)
+++ trunk/LayoutTests/fast/css-grid-layout/grid-template-shorthand-get-set-expected.txt 2016-03-07 10:43:38 UTC (rev 197669)
@@ -165,6 +165,12 @@
PASS element.style.webkitGridTemplateRows is "[head] 15px [tail]"
PASS getComputedStyle(element, '').getPropertyValue('-webkit-grid-template-areas') is "\"a\""
PASS element.style.webkitGridTemplateAreas is "\"a\""
+PASS getComputedStyle(element, '').getPropertyValue('-webkit-grid-template-columns') is "100px"
+PASS element.style.webkitGridTemplateColumns is "100px"
+PASS getComputedStyle(element, '').getPropertyValue('-webkit-grid-template-rows') is "[foo1 bar1] 50px [foo2 bar2 foo3 bar3] 50px [foo4 bar4]"
+PASS element.style.webkitGridTemplateRows is "[foo1 bar1] 50px [foo2 bar2 foo3 bar3] 50px [foo4 bar4]"
+PASS getComputedStyle(element, '').getPropertyValue('-webkit-grid-template-areas') is "\"a\" \"b\""
+PASS element.style.webkitGridTemplateAreas is "\"a\" \"b\""
PASS getComputedStyle(element, '').getPropertyValue('-webkit-grid-template-columns') is "none"
PASS element.style.webkitGridTemplateColumns is "none"
PASS getComputedStyle(element, '').getPropertyValue('-webkit-grid-template-rows') is "0px"
Modified: trunk/LayoutTests/fast/css-grid-layout/grid-template-shorthand-get-set.html (197668 => 197669)
--- trunk/LayoutTests/fast/css-grid-layout/grid-template-shorthand-get-set.html 2016-03-07 10:19:27 UTC (rev 197668)
+++ trunk/LayoutTests/fast/css-grid-layout/grid-template-shorthand-get-set.html 2016-03-07 10:43:38 UTC (rev 197669)
@@ -251,6 +251,7 @@
debug("Test getting and setting grid-template shorthand through JS");
testGridDefinitionsSetJSValues("66px / 18px", "18px", "66px", "none");
testGridDefinitionsSetJSValues("[head] 'a' 15px [tail] / 10px", "10px", "[head] 15px [tail]", "\"a\"");
+ testGridDefinitionsSetJSValues("[foo1 bar1] 'a' 50px [foo2 bar2] [foo3 bar3] 'b' 50px [foo4 bar4] / 100px", "100px", "[foo1 bar1] 50px [foo2 bar2 foo3 bar3] 50px [foo4 bar4]", "\"a\" \"b\"");
testGridDefinitionsSetJSValues("'a'", "none", "0px", "\"a\"", "none", "auto");
debug("");
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes