gecko-dev/dom/simpledb/test/xpcshell/head.js
Jan Varga 2eccc782cd Bug 1917457 - Add a test for origin clearing requested right after starting client directory opening for SDB; r=dom-storage-reviewers,jari
The client directory lock gets invalidated, but the lock is not checked by SDB,
so it's not dropped as soon as possible which can eventually lead to a hang.

Differential Revision: https://phabricator.services.mozilla.com/D219603
2024-09-16 16:58:38 +00:00

24 lines
611 B
JavaScript

/**
* Any copyright is dedicated to the Public Domain.
* http://creativecommons.org/publicdomain/zero/1.0/
*/
add_setup(async function () {
const { setStoragePrefs, clearStoragePrefs } = ChromeUtils.importESModule(
"resource://testing-common/dom/quota/test/modules/StorageUtils.sys.mjs"
);
setStoragePrefs();
const optionalPrefsToSet = [["dom.simpleDB.enabled", true]];
setStoragePrefs(optionalPrefsToSet);
registerCleanupFunction(async function () {
const optionalPrefsToClear = ["dom.simpleDB.enabled"];
clearStoragePrefs(optionalPrefsToClear);
});
do_get_profile();
});