Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / fast / dom / HTMLDocument / document-plugins.html
1 <html>
2 <head>
3 <script>
4 function print(message) {
5     var paragraph = document.createElement("p");
6     paragraph.appendChild(document.createTextNode(message));
7     document.getElementById("console").appendChild(paragraph);
8 }
9
10 function test() {
11     if (window.testRunner) {
12         testRunner.dumpAsText();
13     }
14
15     var pass = true;
16     
17     var embeds = document.embeds;
18     var plugins = document.plugins;
19     
20     if (embeds[0].id != 'embed0' || embeds[1].id != 'embed1')
21         pass = false;
22     if (plugins[0] != embeds[0] || plugins[1] != embeds[1])
23         pass = false;
24
25     print(pass ? "PASS" : "FAIL");
26 }
27 </script>
28 </head>
29 <body onload="test();">
30 <p>This test checks for whether document.plugins matches document.embeds.</p>
31 <p>If the test passes, you will see a pass message below.</p>
32 <hr>
33 <div id='console'></div>
34 <embed id = 'embed0' width=0 height=0>
35 <embed id = 'embed1' width=0 height=0>
36 </body>
37 </html>