<!DOCTYPE HTML>
<html>
<head></head>
<body>
<p>Test mixed content from unsecure WebSocket within Worker blocked from secure page.</p>
<p></p>
<p>On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".</p>
<pre id=log>
</pre>
<script>
if (location.protocol !== "https:")
    location = "https://127.0.0.1:8443/wesocket/tests/hybi/non-document-mixed-content-blocked.https.html";

if (window.testRunner) {
    testRunner.waitUntilDone();
    testRunner.dumpAsText();
}

if (window.internals)
    internals.settings.setAllowDisplayOfInsecureContent(true);


function log(message)
{
    document.getElementById("log").innerHTML += message + "\n";
}

function endTest()
{
    log("TEST COMPLETE");
    if (window.testRunner)
        testRunner.notifyDone();
}

var worker = new Worker("resources/non-document-mixed-content-blocked.js");
worker.onmessage = function (event)
{
    log(event.data);
    if (event.data == "DONE")
        endTest();
};
</script>
</body>
</html>
