blob: 84dc722622cce16759578b6a9be3ac31a0f5d33c [file] [log] [blame]
<html>
<!--
This test checks to make sure plugins aren't loaded when a page is prerendered,
and are also not loaded once the page is displayed. This is used to test certain
content settings that do not allow plugin loading.
This test relies on the Pepper plugin (but not the placeholder) implementing
the postMessage() function on the plugin object.
-->
<head>
<title>Prerender Plugin Never Load</title>
<script>
// Make sure plugin was not loaded while prerendering.
function DidPrerenderPass() {
// |plugin| should be the blocked plugin placeholder, rather than the
// test plugin.
var plugin = window.document['plugin'];
return plugin.postMessage == undefined;
}
// Make sure plugin still does not load once the page is displayed.
function DidDisplayPass() {
var plugin = window.document['plugin'];
return plugin.postMessage == undefined;
}
</script>
</head>
<body>
<embed name="plugin" type="application/x-ppapi-tests"></embed>
</body>
</html>