Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / HTMLTableRowElement / script-tests / cells.js
bloba3ad0ee85b906857f5793dd2ca65eb56e53f866f
1 description('Test behavior of the HTMLTableRowElement cells attribute in cases where there is unusual nesting.');
3 function checkCellNesting(tag)
5 var row = document.createElement("tr");
6 var container = document.createElement(tag);
7 var cell = document.createElement("td");
8 row.appendChild(container);
9 container.appendChild(cell);
10 return row.cells.length;
13 function checkHeaderCellNesting(tag)
15 var row = document.createElement("tr");
16 var container = document.createElement(tag);
17 var cell = document.createElement("th");
18 row.appendChild(container);
19 container.appendChild(cell);
20 return row.cells.length;
23 var tags = [
24 "col",
25 "colgroup",
26 "div",
27 "form",
28 "script",
29 "table",
30 "tbody",
31 "tfoot",
32 "thead",
33 "tr",
36 for (i = 0; i < tags.length; ++i)
37 shouldBe('checkCellNesting("' + tags[i] + '")', '0');
39 debug('');
41 shouldBe('checkCellNesting("td")', '1');
42 shouldBe('checkCellNesting("th")', '1');
44 debug('');
46 for (i = 0; i < tags.length; ++i)
47 shouldBe('checkHeaderCellNesting("' + tags[i] + '")', '0');
49 debug('');
51 shouldBe('checkHeaderCellNesting("td")', '1');
52 shouldBe('checkHeaderCellNesting("th")', '1');
54 debug('');