mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-24 10:45:42 +00:00
bbbb6b3c68
Differential Revision: https://phabricator.services.mozilla.com/D18960 --HG-- extra : moz-landing-system : lando
17 lines
461 B
JavaScript
17 lines
461 B
JavaScript
CookiePolicyHelper.runTest("SharedWorker", {
|
|
cookieJarAccessAllowed: async w => {
|
|
new w.SharedWorker("a.js", "foo");
|
|
ok(true, "SharedWorker is allowed");
|
|
},
|
|
|
|
cookieJarAccessDenied: async w => {
|
|
try {
|
|
new w.SharedWorker("a.js", "foo");
|
|
ok(false, "SharedWorker cannot be used!");
|
|
} catch (e) {
|
|
ok(true, "SharedWorker cannot be used!");
|
|
is(e.name, "SecurityError", "We want a security error message.");
|
|
}
|
|
},
|
|
});
|