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

Side by Side Diff: LayoutTests/fast/regions/script-tests/region-element-display-restriction.js

Issue 53373003: Remove display:run-in as per https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/_tHSX… (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix test Created 7 years, 1 month 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("Test that only non-replaced block elements can be transformed into regions."); 1 description("Test that only non-replaced block elements can be transformed into regions.");
2 2
3 function createRegionElement(elementType, displayType) 3 function createRegionElement(elementType, displayType)
4 { 4 {
5 var element = document.createElement(elementType); 5 var element = document.createElement(elementType);
6 var textElement = document.createTextNode("inside element"); 6 var textElement = document.createTextNode("inside element");
7 element.appendChild(textElement); 7 element.appendChild(textElement);
8 element.style.setProperty("display", displayType); 8 element.style.setProperty("display", displayType);
9 document.body.appendChild(element); 9 document.body.appendChild(element);
10 10
11 // Transform the element into a region. 11 // Transform the element into a region.
12 element.style.setProperty("-webkit-flow-from", "no-flow"); 12 element.style.setProperty("-webkit-flow-from", "no-flow");
13 13
14 // The region element was created if the length of inner text is 0. 14 // The region element was created if the length of inner text is 0.
15 var regionCreated = element.innerText.length == 0; 15 var regionCreated = element.innerText.length == 0;
16 16
17 document.body.removeChild(element); 17 document.body.removeChild(element);
18 18
19 return regionCreated; 19 return regionCreated;
20 } 20 }
21 21
22 shouldBeFalse('createRegionElement("div", "none")'); 22 shouldBeFalse('createRegionElement("div", "none")');
23 shouldBeTrue('createRegionElement("div", "block")'); 23 shouldBeTrue('createRegionElement("div", "block")');
24 shouldBeTrue('createRegionElement("div", "inline-block")'); 24 shouldBeTrue('createRegionElement("div", "inline-block")');
25 shouldBeFalse('createRegionElement("div", "run-in")');
26 shouldBeFalse('createRegionElement("div", "compact")'); 25 shouldBeFalse('createRegionElement("div", "compact")');
27 shouldBeFalse('createRegionElement("div", "inline")'); 26 shouldBeFalse('createRegionElement("div", "inline")');
28 shouldBeFalse('createRegionElement("div", "table")'); 27 shouldBeFalse('createRegionElement("div", "table")');
29 shouldBeFalse('createRegionElement("div", "inline-table")'); 28 shouldBeFalse('createRegionElement("div", "inline-table")');
30 shouldBeTrue('createRegionElement("div", "table-cell")'); 29 shouldBeTrue('createRegionElement("div", "table-cell")');
31 shouldBeTrue('createRegionElement("div", "table-caption")'); 30 shouldBeTrue('createRegionElement("div", "table-caption")');
32 shouldBeTrue('createRegionElement("div", "list-item")'); 31 shouldBeTrue('createRegionElement("div", "list-item")');
33 shouldBeFalse('createRegionElement("div", "-webkit-box")'); 32 shouldBeFalse('createRegionElement("div", "-webkit-box")');
34 shouldBeFalse('createRegionElement("div", "-webkit-inline-box")'); 33 shouldBeFalse('createRegionElement("div", "-webkit-inline-box")');
35 shouldBeFalse('createRegionElement("div", "-webkit-flex")'); 34 shouldBeFalse('createRegionElement("div", "-webkit-flex")');
36 shouldBeFalse('createRegionElement("div", "-webkit-inline-flex")'); 35 shouldBeFalse('createRegionElement("div", "-webkit-inline-flex")');
37 // FIXME: Also add grid and inline grid when it is enabled by default 36 // FIXME: Also add grid and inline grid when it is enabled by default
OLDNEW
« no previous file with comments | « LayoutTests/fast/regions/script-tests/region-element-display-change.js ('k') | LayoutTests/fast/runin/001.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698