Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1063)

Side by Side Diff: LayoutTests/fast/shapes/parsing/parsing-test-utils.js

Issue 144143005: Preserve shape-box order in non-computed values (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Updating patch to trunk Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Valid values for both shape-inside and shape-outside. Two values are specifie d when the shape property value 1 // Valid values for both shape-inside and shape-outside. Two values are specifie d when the shape property value
2 // differs from the specified value. Three values are specified when the compute d shape property value differs 2 // differs from the specified value. Three values are specified when the compute d shape property value differs
3 // from the specified value. 3 // from the specified value.
4 // eg: "specified value/CSS Text value/computed style value" 4 // eg: "specified value/CSS Text value/computed style value"
5 // or: ["specified value", "CSS Text value/computed style value"] 5 // or: ["specified value", "CSS Text value/computed style value"]
6 // or: ["specified value", "CSS Text value", "Computed style value"] 6 // or: ["specified value", "CSS Text value", "Computed style value"]
7 var validShapeValues = [ 7 var validShapeValues = [
8 "none", 8 "none",
9 ["rectangle(10px, 20px, 30px, 40px)", "rectangle(10px, 20px, 30px, 40px)", " rectangle(10px, 20px, 30px, 40px, 0px, 0px)"], 9 ["rectangle(10px, 20px, 30px, 40px)", "rectangle(10px, 20px, 30px, 40px)", " rectangle(10px, 20px, 30px, 40px, 0px, 0px)"],
10 ["rectangle(10px, 20px, 30px, 40px, 5px)", "rectangle(10px, 20px, 30px, 40px , 5px)", "rectangle(10px, 20px, 30px, 40px, 5px, 5px)"], 10 ["rectangle(10px, 20px, 30px, 40px, 5px)", "rectangle(10px, 20px, 30px, 40px , 5px)", "rectangle(10px, 20px, 30px, 40px, 5px, 5px)"],
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 "content-box", 82 "content-box",
83 "padding-box", 83 "padding-box",
84 "border-box", 84 "border-box",
85 "margin-box", 85 "margin-box",
86 86
87 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) content-box", 87 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) content-box",
88 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) padding-box", 88 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) padding-box",
89 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) border-box", 89 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) border-box",
90 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) margin-box", 90 "polygon(nonzero, 10px 10px, 20px 20px, 30px 30px) margin-box",
91 91
92 ["content-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(n onzero, 10px 10px, 20px 20px, 30px 30px) content-box"], 92 ["content-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "content-b ox polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(nonzero, 10px 10 px, 20px 20px, 30px 30px) content-box"],
93 ["padding-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(n onzero, 10px 10px, 20px 20px, 30px 30px) padding-box"], 93 ["padding-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "padding-b ox polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(nonzero, 10px 10 px, 20px 20px, 30px 30px) padding-box"],
94 ["border-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(no nzero, 10px 10px, 20px 20px, 30px 30px) border-box"], 94 ["border-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "border-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(nonzero, 10px 10px , 20px 20px, 30px 30px) border-box"],
95 ["margin-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(no nzero, 10px 10px, 20px 20px, 30px 30px) margin-box"] 95 ["margin-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "margin-box polygon(nonzero, 10px 10px, 20px 20px, 30px 30px)", "polygon(nonzero, 10px 10px , 20px 20px, 30px 30px) margin-box"]
96 ]; 96 ];
97 97
98 // Invalid values for both shape-inside and shape-outside. When an invalid shape value is specified, the 98 // Invalid values for both shape-inside and shape-outside. When an invalid shape value is specified, the
99 // shape property's computed value is the same as its default. 99 // shape property's computed value is the same as its default.
100 var invalidShapeValues = [ 100 var invalidShapeValues = [
101 "calc()", 101 "calc()",
102 "auto", 102 "auto",
103 103
104 "rectangle()", 104 "rectangle()",
105 "rectangle(10px)", 105 "rectangle(10px)",
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 279
280 function testNotInheritedShapeProperty(property, parentValue, childValue, expect edValue) 280 function testNotInheritedShapeProperty(property, parentValue, childValue, expect edValue)
281 { 281 {
282 shouldBeEqualToString('getParentAndChildComputedStylesString("' + property + '", "' + parentValue + '", "' + childValue + '")', expectedValue); 282 shouldBeEqualToString('getParentAndChildComputedStylesString("' + property + '", "' + parentValue + '", "' + childValue + '")', expectedValue);
283 } 283 }
284 284
285 function applyToEachArglist(testFunction, arglists) 285 function applyToEachArglist(testFunction, arglists)
286 { 286 {
287 arglists.forEach(function(arglist, i, a) {testFunction.apply(null, arglist); }); 287 arglists.forEach(function(arglist, i, a) {testFunction.apply(null, arglist); });
288 } 288 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698