Bug 1808729 - Limit session store writes to once per hour when the user is idle, r=dao.
Differential Revision: https://phabricator.services.mozilla.com/D166099
This commit is contained in:
@@ -51,7 +51,7 @@ add_task(async function testIntervalChanges() {
|
||||
// Increase `idleDelay` to 1 day to update the pre-registered idle observer
|
||||
// in "real" idle service to avoid possible interference, especially for the
|
||||
// CI server environment.
|
||||
Services.prefs.setIntPref("browser.sessionstore.idleDelay", 86400000);
|
||||
Services.prefs.setIntPref("browser.sessionstore.idleDelay", 86400);
|
||||
|
||||
// Mock an idle service.
|
||||
let fakeIdleService = MockRegistrar.register(
|
||||
@@ -67,7 +67,7 @@ add_task(async function testIntervalChanges() {
|
||||
|
||||
// Hook idle/active observer to mock idle service by changing pref `idleDelay`
|
||||
// to a whatever value, which will not be used.
|
||||
Services.prefs.setIntPref("browser.sessionstore.idleDelay", 5000000);
|
||||
Services.prefs.setIntPref("browser.sessionstore.idleDelay", 5000);
|
||||
|
||||
// Wait a `sessionstore-state-write-complete` event from any previous
|
||||
// scheduled state write. This is needed since the `_lastSaveTime` in
|
||||
|
||||
Reference in New Issue
Block a user