diff options
Diffstat (limited to 'testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/secure_context.html')
-rw-r--r-- | testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/secure_context.html | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/secure_context.html b/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/secure_context.html new file mode 100644 index 0000000000..685f5d19d7 --- /dev/null +++ b/testing/web-platform/tests/html/webappapis/system-state-and-capabilities/the-navigator-object/secure_context.html @@ -0,0 +1,18 @@ +<!DOCTYPE HTML> +<html> +<head> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script> + test(t => { + assert_false('registerProtocolHandler' in navigator); + assert_equals(navigator.registerProtocolHandler, undefined); + }, "navigator.registerProtocolHandler does not exist in non-secure contexts."); + + test(t => { + assert_false('unregisterProtocolHandler' in navigator); + assert_equals(navigator.unregisterProtocolHandler, undefined); + }, "navigator.unregisterProtocolHandler does not exist in non-secure contexts."); + </script> +</head> +</html> |