Source code

Revision control

Copy as Markdown

Other Tools

Test Info: Warnings

<!DOCTYPE html>
<meta charset="utf-8">
<link rel="author" href="mailto:masonf@chromium.org">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
test(() => {
const doc = document.implementation.createHTMLDocument();
const popover = doc.createElement('div');
popover.setAttribute('popover','');
doc.body.appendChild(popover);
assert_throws_dom('InvalidStateError',() => popover.showPopover());
assert_false(popover.matches(':popover-open'));
},'showPopover should throw when the document isn\'t active');
</script>