Source code

Revision control

Copy as Markdown

Other Tools

Test Info: Warnings

<!doctype html>
<meta charset=utf-8>
<title>Test all known permissions support</title>
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<div id="log"></div>
// These are marked "at risk" in the spec...
const atRisk = [
// These are known to be supported by multiple engines...
const permissions = [
for (const name of [...permissions, ...atRisk]) {
promise_test(async (test) => {
const status = await navigator.permissions.query({ name });
assert_true(status instanceof PermissionStatus);
//assert_equals(, name, `permission's name should be "${name}"`);
}, `Query "${name}" permission`);