blob: da9efdce777c43e5b3f37bda628884c1a3579fde [file] [log] [blame]
<!doctype html>
<meta name="timeout" content="long">
<title>Cross-Origin-Opener-Policy requires secure contexts</title>
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script>
async_test(t => {
const popup = window.open("/common/blank.html");
assert_equals(window, popup.opener);
t.step_timeout(() => {
assert_false(popup.closed);
assert_equals(popup.location.pathname, "/common/blank.html");
popup.close();
t.done();
}, 500);
}, "Cross-Origin-Opener-Policy only works over secure contexts");
</script>