mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-11 16:32:59 +00:00
Bug 1134334 - Intermittent run-by-dir test_0900_deprecatedUpdateFormat_minor.xul | Checking currentPage.pageid equals checking in pageshow - got downloading, expected checking. r=spohl
This commit is contained in:
parent
57bcfa87be
commit
9d2513bd20
@ -150,6 +150,10 @@ const URI_UPDATE_PROMPT_DIALOG = "chrome://mozapps/content/update/updates.xul";
|
||||
|
||||
const ADDON_ID_SUFFIX = "@appupdatetest.mozilla.org";
|
||||
const ADDON_PREP_DIR = "appupdateprep";
|
||||
|
||||
const PREF_APP_UPDATE_INTERVAL = "app.update.interval";
|
||||
const PREF_APP_UPDATE_LASTUPDATETIME = "app.update.lastUpdateTime.background-update-timer";
|
||||
|
||||
// Preference for storing add-ons that are disabled by the tests to prevent them
|
||||
// from interefering with the tests.
|
||||
const PREF_DISABLEDADDONS = "app.update.test.disabledAddons";
|
||||
@ -877,6 +881,14 @@ function setupPrefs() {
|
||||
Services.prefs.setBoolPref(PREF_APP_UPDATE_LOG, true);
|
||||
}
|
||||
|
||||
// Prevent nsIUpdateTimerManager from notifying nsIApplicationUpdateService
|
||||
// to check for updates by setting the app update last update time to the
|
||||
// current time minus one minute in seconds and the interval time to 12 hours
|
||||
// in seconds.
|
||||
let now = Math.round(Date.now() / 1000) - 60;
|
||||
Services.prefs.setIntPref(PREF_APP_UPDATE_LASTUPDATETIME, now);
|
||||
Services.prefs.setIntPref(PREF_APP_UPDATE_INTERVAL, 43200);
|
||||
|
||||
if (Services.prefs.prefHasUserValue(PREF_APP_UPDATE_URL_OVERRIDE)) {
|
||||
gAppUpdateURL = Services.prefs.getCharPref(PREF_APP_UPDATE_URL_OVERRIDE);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user