Source code

Revision control

Copy as Markdown

Other Tools

Test Info: Warnings

// META: script=/resources/testdriver.js
// META: script=/resources/testdriver-vendor.js
'use strict';
// Step 1 - Try to open secure popin and see failure.
// Step 2 - Try to open insecure popin and see failure.
// Step 3 - Try to open path-only popin and see failure.
// Step 3 - Try to open empty popin and see failure.
async_test(t => {
let targets = "";
// Step 1
try {
targets += "Secure-";
} catch (_) {}
// Step 2
try {
targets += "Insecure-";
} catch (_) {}
// Step 3
try {
window.open("/partitioned-popins/resources/partitioned-popins.close.html", '_blank', 'popin');
targets += "PathOnly-";
} catch (_) {}
// Step 4
try {
window.open("", '_blank', 'popin');
targets += "Empty-";
} catch (_) {}
assert_equals(targets, "");
t.done();
}, "Verify no Partitioned Popins can be opened from insecure page");