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

Side by Side Diff: LayoutTests/fast/shapes/parsing/script-tests/parsing-shape-outside.js

Issue 20806004: Remove Explicit Shapes Enablement in Tests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Enabled by default, no need to call internals Created 7 years, 4 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 description('Testing parsing of the -webkit-shape-outside property.'); 1 description('Testing parsing of the -webkit-shape-outside property.');
2 2
3 if (window.internals)
4 window.internals.settings.setCSSExclusionsEnabled(true);
5
6 // The test functions and globals used here are defined parsing-test-utils.js. 3 // The test functions and globals used here are defined parsing-test-utils.js.
7 4
8 validShapeValues.forEach(function(elt, i, a) { 5 validShapeValues.forEach(function(elt, i, a) {
9 var value = (elt instanceof Array) ? elt[0] : elt; 6 var value = (elt instanceof Array) ? elt[0] : elt;
10 var expectedValue = (elt instanceof Array) ? elt[1] : elt; 7 var expectedValue = (elt instanceof Array) ? elt[1] : elt;
11 var computedValue = (elt instanceof Array && elt.length > 2) ? elt[2] : expe ctedValue; 8 var computedValue = (elt instanceof Array && elt.length > 2) ? elt[2] : expe ctedValue;
12 testShapeSpecifiedProperty("-webkit-shape-outside", value, expectedValue); 9 testShapeSpecifiedProperty("-webkit-shape-outside", value, expectedValue);
13 testShapeComputedProperty("-webkit-shape-outside", value, computedValue); 10 testShapeComputedProperty("-webkit-shape-outside", value, computedValue);
14 }); 11 });
15 12
16 testLocalURLShapeProperty("-webkit-shape-outside", "url(\'image\')", "url(image) "); 13 testLocalURLShapeProperty("-webkit-shape-outside", "url(\'image\')", "url(image) ");
17 14
18 invalidShapeValues.forEach(function(value, i, a) { 15 invalidShapeValues.forEach(function(value, i, a) {
19 testShapePropertyParsingFailure("-webkit-shape-outside", value, "auto") 16 testShapePropertyParsingFailure("-webkit-shape-outside", value, "auto")
20 }); 17 });
21 18
22 testShapePropertyParsingFailure("-webkit-shape-outside", "outside-shape", "auto" ); 19 testShapePropertyParsingFailure("-webkit-shape-outside", "outside-shape", "auto" );
23 20
24 applyToEachArglist( 21 applyToEachArglist(
25 testNotInheritedShapeProperty, 22 testNotInheritedShapeProperty,
26 [// [property, parentValue, childValue, expectedValue] 23 [// [property, parentValue, childValue, expectedValue]
27 ["-webkit-shape-outside", "auto", "rectangle(10px, 20px, 30px, 40px)", "par ent: auto, child: rectangle(10px, 20px, 30px, 40px, 0px, 0px)"], 24 ["-webkit-shape-outside", "auto", "rectangle(10px, 20px, 30px, 40px)", "par ent: auto, child: rectangle(10px, 20px, 30px, 40px, 0px, 0px)"],
28 ["-webkit-shape-outside", "rectangle(10px, 20px, 30px, 40px)", "initial", " parent: rectangle(10px, 20px, 30px, 40px, 0px, 0px), child: auto"], 25 ["-webkit-shape-outside", "rectangle(10px, 20px, 30px, 40px)", "initial", " parent: rectangle(10px, 20px, 30px, 40px, 0px, 0px), child: auto"],
29 ["-webkit-shape-outside", "rectangle(10px, 20px, 30px, 40px)", "", "parent: rectangle(10px, 20px, 30px, 40px, 0px, 0px), child: auto"], 26 ["-webkit-shape-outside", "rectangle(10px, 20px, 30px, 40px)", "", "parent: rectangle(10px, 20px, 30px, 40px, 0px, 0px), child: auto"],
30 ["-webkit-shape-outside", "rectangle(10px, 20px, 30px, 40px)", "inherit", " parent: rectangle(10px, 20px, 30px, 40px, 0px, 0px), child: rectangle(10px, 20px , 30px, 40px, 0px, 0px)"], 27 ["-webkit-shape-outside", "rectangle(10px, 20px, 30px, 40px)", "inherit", " parent: rectangle(10px, 20px, 30px, 40px, 0px, 0px), child: rectangle(10px, 20px , 30px, 40px, 0px, 0px)"],
31 ["-webkit-shape-outside", "", "inherit", "parent: auto, child: auto"], 28 ["-webkit-shape-outside", "", "inherit", "parent: auto, child: auto"],
32 ["-webkit-shape-outside", "auto", "inherit", "parent: auto, child: auto"]] 29 ["-webkit-shape-outside", "auto", "inherit", "parent: auto, child: auto"]]
33 ); 30 );
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698