Bug 1938475 [Wayland] Fallback to monitor screen scale if we're missing wayland surfa...
[gecko.git] / security / manager / ssl / tests / mochitest / mixedcontent / test_dynDelayedUnsecurePicture.html
blobd76af27a8720451f67d51e72c02298da25ce7c7f
1 <!DOCTYPE HTML>
2 <html>
3 <head>
4 <title>img.src changes to unsecure test</title>
5 <script src="/tests/SimpleTest/SimpleTest.js"></script>
6 <script type="text/javascript" src="mixedContentTest.js"></script>
7 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
9 <script class="testbody" type="text/javascript">
10 "use strict";
12 async function runTest()
14 await isSecurityState("secure");
15 window.setTimeout(function() {
16 // Don't do this synchronously from onload handler
17 document.getElementById("image1").src =
18 "http://example.com/tests/security/manager/ssl/tests/mochitest/mixedcontent/moonsurface.jpg";
19 }, 0);
21 waitForSecurityState("broken", async () =>
23 await isSecurityState("broken", "src='http://...' changed to broken");
24 finish();
25 });
28 async function afterNavigationTest()
30 is(document.getElementById("image1").src,
31 "https://example.com/tests/security/manager/ssl/tests/mochitest/mixedcontent/moonsurface.jpg",
32 "img.src secure again");
33 await isSecurityState("secure", "security full after navigation");
34 finish();
37 </script>
38 </head>
40 <body>
41 <img id="image1" src="https://example.com/tests/security/manager/ssl/tests/mochitest/mixedcontent/moonsurface.jpg" />
42 </body>
43 </html>