| OLD | NEW |
| (Empty) |
| 1 <!DOCTYPE html> | |
| 2 <title>getUserMedia On An Insecure Origin</title> | |
| 3 <script src="/resources/testharness.js"></script> | |
| 4 <script src="/resources/testharnessreport.js"></script> | |
| 5 <script src="/resources/get-host-info.js"></script> | |
| 6 <script> | |
| 7 if (window.location.origin != get_host_info().UNAUTHENTICATED_ORIGIN) { | |
| 8 window.location = get_host_info().UNAUTHENTICATED_ORIGIN + window.location.p
athname; | |
| 9 } else { | |
| 10 if (window.testRunner) | |
| 11 testRunner.overridePreference("WebKitStrictPowerfulFeatureRestrictions",
true); | |
| 12 | |
| 13 test(function () { | |
| 14 assert_throws( | |
| 15 "SecurityError", | |
| 16 function() { | |
| 17 navigator.webkitGetUserMedia( | |
| 18 { video:true }, | |
| 19 function() { assert_unreached("Success callback should not b
e called."); }, | |
| 20 function() { assert_unreached("Error callback should not be
called."); }); | |
| 21 }); | |
| 22 }, 'getUserMedia'); | |
| 23 } | |
| 24 </script> | |
| OLD | NEW |