pulled in sync tests
This commit is contained in:
parent
26cd3c3cc8
commit
d033292784
2 changed files with 6 additions and 4 deletions
|
@ -45,7 +45,7 @@
|
||||||
"package": "rm -rf src/web-ext-artifacts && npm run build && mv src/web-ext-artifacts/firefox_multi-account_containers-*.zip addon.xpi",
|
"package": "rm -rf src/web-ext-artifacts && npm run build && mv src/web-ext-artifacts/firefox_multi-account_containers-*.zip addon.xpi",
|
||||||
"test": "npm run lint && npm run coverage",
|
"test": "npm run lint && npm run coverage",
|
||||||
"mocha": "mocha ./test/setup.js test/**/*.test.js",
|
"mocha": "mocha ./test/setup.js test/**/*.test.js",
|
||||||
"mochaSingle": "mocha",
|
"mochaSingle": "mocha ./test/setup.js",
|
||||||
"test-watch": "mocha ./test/setup.js test/**/*.test.js --watch",
|
"test-watch": "mocha ./test/setup.js test/**/*.test.js --watch",
|
||||||
"coverage": "nyc --reporter=html --reporter=text mocha ./test/setup.js test/**/*.test.js --timeout 60000"
|
"coverage": "nyc --reporter=html --reporter=text mocha ./test/setup.js test/**/*.test.js --timeout 60000"
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
const SYNC_DEBUG = true;
|
const SYNC_DEBUG = false;
|
||||||
|
|
||||||
const sync = {
|
const sync = {
|
||||||
storageArea: {
|
storageArea: {
|
||||||
|
@ -153,8 +153,10 @@ const sync = {
|
||||||
async initSync() {
|
async initSync() {
|
||||||
const syncInfo = await sync.storageArea.get();
|
const syncInfo = await sync.storageArea.get();
|
||||||
const localInfo = await browser.storage.local.get();
|
const localInfo = await browser.storage.local.get();
|
||||||
|
if (SYNC_DEBUG) {
|
||||||
console.log("inSync: ", syncInfo);
|
console.log("inSync: ", syncInfo);
|
||||||
console.log("inLocal: ", localInfo);
|
console.log("inLocal: ", localInfo);
|
||||||
|
}
|
||||||
const beenSynced = await assignManager.storageArea.getSynced();
|
const beenSynced = await assignManager.storageArea.getSynced();
|
||||||
if (beenSynced){
|
if (beenSynced){
|
||||||
runSync();
|
runSync();
|
||||||
|
|
Loading…
Add table
Reference in a new issue