Bug 881270 - Remove the MIME type fallback tests in test_bug391728 because they are testing the incorrect behavior and only happen to work because the test plugin remained blocklisted from a prior test. r=johns

--HG--
extra : rebase_source : c7b1d6e6f50f35598d8ca98c1527673542c6798d
This commit is contained in:
Benjamin Smedberg 2013-06-11 10:58:42 -04:00
parent cbe825d9c7
commit d6bcd644f8
3 changed files with 15 additions and 23 deletions

View File

@ -36,24 +36,20 @@ document.addEventListener("PluginBindingAttached", plugin_binding_attached, true
<div><object id="plugin3" style="width: 100px; height: 100px" type="application/x-test"></object></div>
<div><object id="plugin4" style="width: 100px; height: 100px" data="data:application/x-test,test"></object></div>
<!-- The mimetype of the actual data is supposed to be used in preference -->
<div><embed id="plugin5" style="width: 100px; height: 100px" type="application/x-unknown" src="data:application/x-test,test"></div>
<div><object id="plugin6" style="width: 100px; height: 100px" type="application/x-unknown" data="data:application/x-test,test"></object></div>
<!-- Params are not considered content -->
<div><object id="plugin7" style="width: 100px; height: 100px" type="application/x-test">
<div><object id="plugin5" style="width: 100px; height: 100px" type="application/x-test">
<param name="foo" value="bar">
</object></div>
<div><object id="plugin8" style="width: 100px; height: 100px" data="data:application/x-test,test">
<div><object id="plugin6" style="width: 100px; height: 100px" data="data:application/x-test,test">
<param name="foo" value="bar">
</object></div>
<!-- Nor is whitespace -->
<div><object id="plugin9" style="width: 100px; height: 100px" type="application/x-test">
<div><object id="plugin7" style="width: 100px; height: 100px" type="application/x-test">
</object></div>
<div><object id="plugin10" style="width: 100px; height: 100px" data="data:application/x-test,test">
<div><object id="plugin8" style="width: 100px; height: 100px" data="data:application/x-test,test">
</object></div>
@ -69,14 +65,14 @@ document.addEventListener("PluginBindingAttached", plugin_binding_attached, true
<!-- Even other plugins are considered content so no errors dispatched from these
objects, but the inner embeds do get processed -->
<div><object id="fallback3" style="width: 100px; height: 100px" type="application/x-test">
<embed id="plugin11" style="width: 100px; height: 100px" type="application/x-test">
<embed id="plugin9" style="width: 100px; height: 100px" type="application/x-test">
</object></div>
<div><object id="fallback4" style="width: 100px; height: 100px" data="data:application/x-test,test">
<embed id="plugin12" style="width: 100px; height: 100px" type="application/x-test">
<embed id="plugin10" style="width: 100px; height: 100px" type="application/x-test">
</object></div>
<!-- pluginurl was removed in bug 548133, and should not affect fallback -->
<div><object id="plugin13" style="width: 100px; height: 100px" data="data:application/x-test,test">
<div><object id="plugin11" style="width: 100px; height: 100px" data="data:application/x-test,test">
<param name="pluginurl">
</object></div>

View File

@ -36,24 +36,20 @@ document.addEventListener("PluginBindingAttached", plugin_binding_attached, true
<div><object id="plugin3" style="width: 100px; height: 100px" type="application/x-unknown"></object></div>
<div><object id="plugin4" style="width: 100px; height: 100px" data="data:application/x-unknown,test"></object></div>
<!-- The mimetype of the actual data is supposed to be used in preference -->
<div><embed id="plugin5" style="width: 100px; height: 100px" type="application/x-test" src="data:application/x-unknown,test"></div>
<div><object id="plugin6" style="width: 100px; height: 100px" type="application/x-test" data="data:application/x-unknown,test"></object></div>
<!-- Params are not considered content -->
<div><object id="plugin7" style="width: 100px; height: 100px" type="application/x-unknown">
<div><object id="plugin5" style="width: 100px; height: 100px" type="application/x-unknown">
<param name="foo" value="bar">
</object></div>
<div><object id="plugin8" style="width: 100px; height: 100px" data="data:application/x-unknown,test">
<div><object id="plugin6" style="width: 100px; height: 100px" data="data:application/x-unknown,test">
<param name="foo" value="bar">
</object></div>
<!-- Nor is whitespace -->
<div><object id="plugin9" style="width: 100px; height: 100px" type="application/x-unknown">
<div><object id="plugin7" style="width: 100px; height: 100px" type="application/x-unknown">
</object></div>
<div><object id="plugin10" style="width: 100px; height: 100px" data="data:application/x-unknown,test">
<div><object id="plugin8" style="width: 100px; height: 100px" data="data:application/x-unknown,test">
</object></div>
@ -69,14 +65,14 @@ document.addEventListener("PluginBindingAttached", plugin_binding_attached, true
<!-- Even other plugins are considered content so no errors dispatched from these
objects, but the inner embeds do get processed -->
<div><object id="fallback3" style="width: 100px; height: 100px" type="application/x-unknown">
<embed id="plugin11" style="width: 100px; height: 100px" type="application/x-unknown">
<embed id="plugin9" style="width: 100px; height: 100px" type="application/x-unknown">
</object></div>
<div><object id="fallback4" style="width: 100px; height: 100px" data="data:application/x-unknown,test">
<embed id="plugin12" style="width: 100px; height: 100px" type="application/x-unknown">
<embed id="plugin10" style="width: 100px; height: 100px" type="application/x-unknown">
</object></div>
<!-- pluginurl was removed in bug 548133, and should not affect fallback -->
<div><object id="plugin13" style="width: 100px; height: 100px" type="application/x-unknown">
<div><object id="plugin11" style="width: 100px; height: 100px" type="application/x-unknown">
<param name="pluginurl">
</object></div>

View File

@ -19,7 +19,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=391728
<script class="testbody" type="text/javascript">
/** Test for Bug 391728 **/
// Plugins that should dispatch error events and have the pseudo classes set
const PLUGIN_COUNT = 13;
const PLUGIN_COUNT = 11;
// Plugins that should neither dispatch error events or have the pseudo classes set
const FALLBACK_COUNT = 5;
const OBJLC = Components.interfaces.nsIObjectLoadingContent;