https://github.com/web-platform-tests/wpt
Raw File
Tip revision: d8ba6d01bab767c9f8825d55e01e6802be81e44e authored by Robert Ma on 21 December 2018, 20:58:11 UTC
Produce a valid report when no tests are affected
Tip revision: d8ba6d0
require_securecontext.html
<!doctype html>
<meta charset=utf-8>
<title>Test that Credential Management requires secure contexts</title>
<link rel="help" href="https://w3c.github.io/webappsec-credential-management/#idl-index">
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script>
"use strict";
  test(() => {
    assert_false(isSecureContext);
    assert_false('credentials' in navigator);
  }, "Credential Management must not be accessible in insecure contexts");
</script>
back to top