mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-11-11 13:48:23 +02:00
Differential Revision: https://phabricator.services.mozilla.com/D25778 --HG-- extra : moz-landing-system : lando
21 lines
700 B
JavaScript
21 lines
700 B
JavaScript
/* import-globals-from storageprincipal_head.js */
|
|
|
|
StoragePrincipalHelper.runTest("DOMCache",
|
|
async (win3rdParty, win1stParty, allowed) => {
|
|
// DOM Cache is not supported. Always blocked.
|
|
await win3rdParty.caches.open("wow").then(
|
|
_ => { ok(allowed, "DOM Cache cannot be used!"); },
|
|
_ => { ok(!allowed, "DOM Cache cannot be used!"); }
|
|
);
|
|
|
|
await win1stParty.caches.open("wow").then(
|
|
_ => { ok(true, "DOM Cache shoulw be available"); },
|
|
_ => { ok(false, "DOM Cache shoulw be available"); },
|
|
);
|
|
},
|
|
|
|
async _ => {
|
|
await new Promise(resolve => {
|
|
Services.clearData.deleteData(Ci.nsIClearDataService.CLEAR_ALL, value => resolve());
|
|
});
|
|
});
|