Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / NodeList / childNodes-reverse-iteration.html
blobdff3286cd7d2405af2612de92da8b5e4f91d70d4
1 <!DOCTYPE html>
2 <html>
3 <body>
4 <p>This is an integration test for childNodes. You should see 1 through 5 below.</p>
5 <pre></pre>
6 <div id="console"></div>
7 <script src="../../../resources/js-test.js"></script>
8 <script>
10 if (window.testRunner)
11 testRunner.dumpAsText();
13 var node = document.querySelector('pre');
14 var failed = false;
15 for (var j = 0; j < 5; ++j) {
16 var child = document.createElement('div');
17 child.innerHTML = j + 1;
18 node.appendChild(child);
19 for (var i = node.childNodes.length - 1; i >= 0; --i) {
20 var actual = node.childNodes[i] ? node.childNodes[i].innerHTML : undefined;
21 if (actual != i + 1) {
22 testFailed('Got ' + actual + ' on ' + (i + 1) + 'st/nd/th child after adding ' + (j + 1) + 'st/nd/th child.');
23 failed = true;
28 shouldBe("node.innerText", "'1\\n2\\n3\\n4\\n5\\n'");
30 </script>
31 </body>
32 </html>