OLD | NEW |
1 <!DOCTYPE HTML> | 1 <!DOCTYPE HTML> |
2 <html> | 2 <html> |
3 <body> | 3 <body> |
4 <p>Tests that reparenting marquee elements also reparents ActiveDOMObject.</p> | 4 <p>Tests that reparenting marquee elements also reparents ActiveDOMObject.</p> |
5 <iframe src="resources/marquee-frame.html"></iframe> | 5 <iframe src="resources/marquee-frame.html"></iframe> |
6 <script src="resources/activedomobject-test.js"></script> | 6 <script src="resources/activedomobject-test.js"></script> |
7 <script> | 7 <script> |
8 function runTest() | 8 function runTest() |
9 { | 9 { |
10 window.iframe = document.querySelector('iframe').contentDocument; | 10 window.iframe = document.querySelector('iframe').contentDocument; |
11 | 11 |
12 log('Before Reparenting'); | 12 log('Before Reparenting'); |
13 shouldBe('window.internals.activeDOMObjectCount(document)', 2); | 13 shouldBe('window.internals.activeDOMObjectCount(document)', 2); |
14 shouldBe('window.internals.activeDOMObjectCount(iframe)', 3); | 14 shouldBe('window.internals.activeDOMObjectCount(iframe)', 2); |
15 | 15 |
16 document.body.appendChild(window.iframe.querySelector('marquee')); | 16 document.body.appendChild(window.iframe.querySelector('marquee')); |
17 | 17 |
18 log('After Reparenting'); | 18 log('After Reparenting'); |
19 shouldBe('window.internals.activeDOMObjectCount(document)', 3); | 19 shouldBe('window.internals.activeDOMObjectCount(document)', 2); |
20 shouldBe('window.internals.activeDOMObjectCount(iframe)', 2); | 20 shouldBe('window.internals.activeDOMObjectCount(iframe)', 2); |
21 } | 21 } |
22 </script> | 22 </script> |
23 </body> | 23 </body> |
24 </html> | 24 </html> |
OLD | NEW |