OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <script src="/js-test-resources/testharness.js"></script> | 4 <script src="/js-test-resources/testharness.js"></script> |
5 <script src="/js-test-resources/testharnessreport.js"></script> | 5 <script src="/js-test-resources/testharnessreport.js"></script> |
6 <script> | 6 <script> |
7 | 7 |
8 if (window.testRunner) { | 8 if (window.testRunner) { |
9 testRunner.setCanOpenWindows(); | 9 testRunner.setCanOpenWindows(); |
10 testRunner.setCloseRemainingWindowsWhenComplete(true); | 10 testRunner.setCloseRemainingWindowsWhenComplete(true); |
11 testRunner.overridePreference("WebKitAllowRunningInsecureContent", false); | 11 testRunner.overridePreference("WebKitAllowRunningInsecureContent", false); |
12 } | 12 } |
| 13 if (window.internals) |
| 14 internals.settings.setLaxMixedContentCheckingEnabled(false); |
| 15 |
13 | 16 |
14 var test = async_test("Test that an insecure WebSocket connection is blocked whe
n created in a worker created from HTTPS resource."); | 17 var test = async_test("Test that an insecure WebSocket connection is blocked whe
n created in a worker created from HTTPS resource."); |
15 test.step(function () | 18 test.step(function () |
16 { | 19 { |
17 window.addEventListener("message", test.step_func(function (evt) | 20 window.addEventListener("message", test.step_func(function (evt) |
18 { | 21 { |
19 assert_equals(evt.data, "DONE", "evt.data"); | 22 assert_equals(evt.data, "DONE", "evt.data"); |
20 test.done(); | 23 test.done(); |
21 }), false); | 24 }), false); |
22 | 25 |
23 window.open("https://127.0.0.1:8443/security/mixedContent/websocket/resource
s/expect-throw-on-construction-worker.html"); | 26 window.open("https://127.0.0.1:8443/security/mixedContent/websocket/resource
s/expect-throw-on-construction-worker.html"); |
24 }); | 27 }); |
25 | 28 |
26 </script> | 29 </script> |
27 </head> | 30 </head> |
28 <body> | 31 <body> |
29 </body> | 32 </body> |
30 </html> | 33 </html> |
OLD | NEW |