| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <head> | 2 <head> |
| 3 <script> | 3 <script> |
| 4 function print(message) | 4 function print(message) |
| 5 { | 5 { |
| 6 var paragraph = document.createElement("p"); | 6 var paragraph = document.createElement("p"); |
| 7 paragraph.appendChild(document.createTextNode(message)); | 7 paragraph.appendChild(document.createTextNode(message)); |
| 8 document.getElementById("console").appendChild(paragraph); | 8 document.getElementById("console").appendChild(paragraph); |
| 9 } | 9 } |
| 10 | 10 |
| 11 function test() | 11 function test() |
| 12 { | 12 { |
| 13 if (window.testRunner) { | 13 if (window.testRunner) { |
| 14 testRunner.dumpAsText(); | 14 testRunner.dumpAsText(); |
| 15 } | 15 } |
| 16 | 16 |
| 17 print("plugin <object> with nested plugin <embed>: should have a plugin and
does " + (document.getElementById('myO').testCallback ? "" : "not")); | 17 print("plugin <object> with nested plugin <embed>: should have a plugin and
does " + (document.getElementById('myO').testCallback ? "" : "not")); |
| 18 print("plugin <embed> netsted in plugin <object>: should have a plugin and d
oes " + (document.getElementById('myE').testCallback ? "" : "not")); | 18 print("plugin <embed> netsted in plugin <object>: should have a plugin and d
oes " + (document.getElementById('myE').testCallback ? "" : "not")); |
| 19 print("empty <object> with nested plugin <embed>: should not have a plugin a
nd does " + (document.getElementById('myO2').testCallback ? "" : "not")); | 19 print("empty <object> with nested plugin <embed>: should not have a plugin a
nd does " + (document.getElementById('myO2').testCallback ? "" : "not")); |
| 20 print("plugin <embed> nested in empty <object>: should have a plugin and doe
s " + (document.getElementById('myE2').testCallback ? "" : "not")); | 20 print("plugin <embed> nested in empty <object>: should have a plugin and doe
s " + (document.getElementById('myE2').testCallback ? "" : "not")); |
| 21 print("plugin <embed> nested in image <object>: should not have a plugin and
does " + (document.getElementById('myE3').testCallback ? "" : "not")); | 21 print("plugin <embed> nested in image <object>: should not have a plugin and
does " + (document.getElementById('myE3').testCallback ? "" : "not")); |
| 22 print("plugin <embed> nested in empty <object> nested in plugin <object>: sh
ould not have a plugin and does " + (document.getElementById('myE4').testCallbac
k ? "" : "not")); | 22 print("plugin <embed> nested in empty <object> nested in plugin <object>: sh
ould not have a plugin and does " + (document.getElementById('myE4').testCallbac
k ? "" : "not")); |
| 23 print("standalone plugin <embed>: should have a plugin and does " + (documen
t.getElementById('myE5').testCallback ? "" : "not")); | 23 print("standalone plugin <embed>: should have a plugin and does " + (documen
t.getElementById('myE5').testCallback ? "" : "not")); |
| 24 print("plugin <object> with nested plugin <embed> of the same name should ha
ve a plugin and does " + (document.Plugin.testCallback ? "" : "not")); | 24 |
| 25 print("empty <object> with nested plugin <embed> of the same name should hav
e a plugin and does " + (document.Plugin2.testCallback ? "" : "not")); | 25 function showPlugin(p) { |
| 26 return p.testCallback ? ("[" + p.getAttribute('location') + "]") : "not"
; |
| 27 } |
| 28 print("plugin <object> with nested plugin <embed> of the same name should ha
ve an <embed> plugin and does " + showPlugin(document.Plugin)); |
| 29 print("empty <object> with nested plugin <embed> of the same name should hav
e an <embed> plugin and does " + showPlugin(document.Plugin2)); |
| 26 } | 30 } |
| 27 </script> | 31 </script> |
| 28 </head> | 32 </head> |
| 29 <body onload="test()"> | 33 <body onload="test()"> |
| 30 <p>This test checks for a regression against <i>rdar://problem/4214080 document.
embeds: embeds[0].Play() undefined at languageguide.org</i>.</p> | 34 <p>This test checks for a regression against <i>rdar://problem/4214080 document.
embeds: embeds[0].Play() undefined at languageguide.org</i>.</p> |
| 31 <p>Each test below states its expected outcome.</p> | 35 <p>Each test below states its expected outcome.</p> |
| 32 <hr> | 36 <hr> |
| 33 <div id="console"></div> | 37 <div id="console"></div> |
| 34 | 38 |
| 35 <OBJECT | 39 <OBJECT |
| 36 id="myO" | 40 id="myO" |
| 37 type="application/x-webkit-test-netscape" | 41 type="application/x-webkit-test-netscape" |
| 38 width = 0 height = 0 | 42 width = 0 height = 0 |
| 39 > | 43 > |
| 40 <PARAM name="src" value="resources/simple_blank.swf"> | 44 <PARAM name="src" value="resources/simple_blank.swf"> |
| 41 <PARAM name="autostart" value="false"> | 45 <PARAM name="autostart" value="false"> |
| 42 | 46 |
| 43 <EMBED | 47 <EMBED |
| 44 id="myE" | 48 id="myE" |
| 45 type="application/x-webkit-test-netscape" | 49 type="application/x-webkit-test-netscape" |
| 46 autostart="false" | 50 autostart="false" |
| 47 enablejavascript="true" | 51 enablejavascript="true" |
| 48 width = 0 height = 0 | 52 width = 0 height = 0 |
| 49 > | 53 > |
| 50 </EMBED> | 54 </EMBED> |
| 51 </OBJECT> | 55 </OBJECT> |
| 52 | 56 |
| 53 <object id="myO2"> | 57 <object id="myO2"> |
| 54 <embed | 58 <embed |
| 55 id="myE2" | 59 id="myE2" |
| 56 type="application/x-webkit-test-netscape" | 60 type="application/x-webkit-test-netscape" |
| 57 autostart="false" | 61 autostart="false" |
| 58 enablejavascript="true" | 62 enablejavascript="true" |
| 59 width = 0 height = 0 | 63 width = 0 height = 0 |
| 60 > | 64 > |
| 61 </object> | 65 </object> |
| 62 | 66 |
| 63 <object | 67 <object |
| 64 data="resources/apple.gif" | 68 data="resources/apple.gif" |
| 65 type="image/gif" | 69 type="image/gif" |
| 66 width = 0 height = 0 | 70 width = 0 height = 0 |
| 67 > | 71 > |
| 68 <embed | 72 <embed |
| 69 id="myE3" | 73 id="myE3" |
| 70 type="application/x-webkit-test-netscape" | 74 type="application/x-webkit-test-netscape" |
| 71 autostart="false" | 75 autostart="false" |
| 72 enablejavascript="true" | 76 enablejavascript="true" |
| 73 width = 0 height = 0 | 77 width = 0 height = 0 |
| 74 > | 78 > |
| 75 </object> | 79 </object> |
| 76 | 80 |
| 77 <object | 81 <object |
| 78 data="resources/apple.gif" | 82 data="resources/apple.gif" |
| 79 type="image/gif" | 83 type="image/gif" |
| 80 width = 0 height = 0 | 84 width = 0 height = 0 |
| 81 > | 85 > |
| 82 <object> | 86 <object> |
| 83 <embed | 87 <embed |
| 84 id="myE4" | 88 id="myE4" |
| 85 type="application/x-webkit-test-netscape" | 89 type="application/x-webkit-test-netscape" |
| 86 autostart="false" | 90 autostart="false" |
| 87 enablejavascript="true" | 91 enablejavascript="true" |
| 88 width = 0 height = 0 | 92 width = 0 height = 0 |
| 89 > | 93 > |
| 90 </object> | 94 </object> |
| 91 </object> | 95 </object> |
| 92 | 96 |
| 93 <embed | 97 <embed |
| 94 id="myE5" | 98 id="myE5" |
| 95 type="application/x-webkit-test-netscape" | 99 type="application/x-webkit-test-netscape" |
| 96 autostart="false" | 100 autostart="false" |
| 97 enablejavascript="true" | 101 enablejavascript="true" |
| 98 width = 0 height = 0 | 102 width = 0 height = 0 |
| 99 > | 103 > |
| 100 | 104 |
| 101 <object | 105 <object |
| 102 name="Plugin" | 106 name="Plugin" |
| 103 type="application/x-webkit-test-netscape" | 107 type="application/x-webkit-test-netscape" |
| 104 width = 0 height = 0 | 108 width = 0 height = 0 |
| 109 location="outer" |
| 105 > | 110 > |
| 106 <param name="src" value="resources/simple_blank.swf"> | 111 <param name="src" value="resources/simple_blank.swf"> |
| 107 <param name="autostart" value="false"> | 112 <param name="autostart" value="false"> |
| 108 <param name="enablejavascript" value="true"> | 113 <param name="enablejavascript" value="true"> |
| 109 | 114 |
| 110 <embed | 115 <embed |
| 111 name="Plugin" | 116 name="Plugin" |
| 112 type="application/x-webkit-test-netscape" | 117 type="application/x-webkit-test-netscape" |
| 113 autostart="false" | 118 autostart="false" |
| 114 enablejavascript="true" | 119 enablejavascript="true" |
| 115 width = 0 height = 0 | 120 width = 0 height = 0 |
| 121 location="inner" |
| 116 > | 122 > |
| 117 </embed> | 123 </embed> |
| 118 </object> | 124 </object> |
| 119 | 125 |
| 120 <object name="Plugin2"> | 126 <object name="Plugin2" location="outer"> |
| 121 <embed | 127 <embed |
| 122 name="Plugin2" | 128 name="Plugin2" |
| 123 type="application/x-webkit-test-netscape" | 129 type="application/x-webkit-test-netscape" |
| 124 autostart="false" | 130 autostart="false" |
| 125 enablejavascript="true" | 131 enablejavascript="true" |
| 126 width = 0 height = 0 | 132 width = 0 height = 0 |
| 133 location="inner" |
| 127 > | 134 > |
| 128 </embed> | 135 </embed> |
| 129 </object> | 136 </object> |
| 130 | 137 |
| 131 </body> | 138 </body> |
| 132 </html> | 139 </html> |
| OLD | NEW |