mirror of
https://github.com/roytam1/palemoon27.git
synced 2026-05-26 14:18:48 +00:00
f672f60d2d
- Bug 1135100 - Don't update GC thing pointers that haven't changed after marking r=terrence (0df3ea820) - Bug 1135857 - Remove ContentClientIncremental. r=mattwoodrow (059587352) - Bug 1135809 - add apz. prefs to about:support. r=kats (6439aaf6b) - Bug 1135361 - Fix position of ruby annotation in vertical-rl mode when justification is applied to the base. r=jfkthame (a00bb53be) - Bug 1133288 - Remove nonstandard expression closures from editor. r=ehsan (605992184) - Bug 1135361 - Reftest for ruby positioning in justified vertical text. r=xidorn (60fe87ae3) - Bug 1135984 - Fix typo which made Context.__init__ set the unused exe (312c35ef2) - Bug 1077864, Part 1: Check consistency of certificates' signature and signatureAlgorithm fields, r=keeler (9a11f90c3) - Bug 1077864, Part 2: Override the trust level for OCSP response signer certs so that they are never considered trust anchors, r=keeler (c46772e6d) - Bug 1077864, Part 3: update nsserrors.properties so error message gets localized. (935233549) - Bug 1135407: Factor out duplicate logic in tests, r=keeler (383ff80c5) - Bug 1131767: Prune away paths using unacceptable algorithms earlier, r=keeler (55182b7e2) - Followup to Bug 1135563 - uiUnsupportedAlreadyNotified.js doesn't use httpd.js. r=me (cef9dbdcd) - Bug 1135563 - Fix several javascript warnings for xpcshell app update tests and cleanup style. r=spohl (6330eb78c) - Bug 1123019 - In DrawTargetTiled::StrokeRect and StrokeLine, skip tiles that don't intersect the stroke. r=jrmuizel (71afc7653) - Bug 1123019 - Shrink clipped stroked rectangles and stroked lines. r=jrmuizel (17e93d70f) - Bug 1123019 - Actually use the clipped rect variable. r=jrmuizel (29c96ab43)
123 lines
4.0 KiB
JavaScript
123 lines
4.0 KiB
JavaScript
/* Any copyright is dedicated to the Public Domain.
|
|
* http://creativecommons.org/publicdomain/zero/1.0/
|
|
*/
|
|
|
|
function run_test() {
|
|
setupTestCommon();
|
|
|
|
logTestInfo("testing nsIUpdatePrompt notifications should not be displayed " +
|
|
"when showUpdateAvailable is called for an unsupported system " +
|
|
"update when the unsupported notification has already been " +
|
|
"shown (bug 843497)");
|
|
|
|
setUpdateURLOverride();
|
|
// The mock XMLHttpRequest is MUCH faster
|
|
overrideXHR(callHandleEvent);
|
|
standardInit();
|
|
|
|
let registrar = Components.manager.QueryInterface(AUS_Ci.nsIComponentRegistrar);
|
|
registrar.registerFactory(Components.ID("{1dfeb90a-2193-45d5-9cb8-864928b2af55}"),
|
|
"Fake Window Watcher",
|
|
"@mozilla.org/embedcomp/window-watcher;1",
|
|
WindowWatcherFactory);
|
|
registrar.registerFactory(Components.ID("{1dfeb90a-2193-45d5-9cb8-864928b2af56}"),
|
|
"Fake Window Mediator",
|
|
"@mozilla.org/appshell/window-mediator;1",
|
|
WindowMediatorFactory);
|
|
|
|
Services.prefs.setBoolPref(PREF_APP_UPDATE_SILENT, false);
|
|
Services.prefs.setBoolPref(PREF_APP_UPDATE_NOTIFIEDUNSUPPORTED, true);
|
|
// This preference is used to determine when the background update check has
|
|
// completed since a successful check will clear the preference.
|
|
Services.prefs.setIntPref(PREF_APP_UPDATE_BACKGROUNDERRORS, 1);
|
|
|
|
gResponseBody = getRemoteUpdatesXMLString(" <update type=\"major\" " +
|
|
"name=\"Unsupported Update\" " +
|
|
"unsupported=\"true\" " +
|
|
"detailsURL=\"" + URL_HOST +
|
|
"\"></update>\n");
|
|
gAUS.notify(null);
|
|
do_execute_soon(check_test);
|
|
}
|
|
|
|
function check_test() {
|
|
if (Services.prefs.prefHasUserValue(PREF_APP_UPDATE_BACKGROUNDERRORS)) {
|
|
do_execute_soon(check_test);
|
|
return;
|
|
}
|
|
do_check_true(true);
|
|
|
|
doTestFinish();
|
|
}
|
|
|
|
function end_test() {
|
|
let registrar = Components.manager.QueryInterface(AUS_Ci.nsIComponentRegistrar);
|
|
registrar.unregisterFactory(Components.ID("{1dfeb90a-2193-45d5-9cb8-864928b2af55}"),
|
|
WindowWatcherFactory);
|
|
registrar.unregisterFactory(Components.ID("{1dfeb90a-2193-45d5-9cb8-864928b2af56}"),
|
|
WindowMediatorFactory);
|
|
}
|
|
|
|
// Callback function used by the custom XMLHttpRequest implementation to
|
|
// call the nsIDOMEventListener's handleEvent method for onload.
|
|
function callHandleEvent() {
|
|
gXHR.status = 400;
|
|
gXHR.responseText = gResponseBody;
|
|
try {
|
|
var parser = AUS_Cc["@mozilla.org/xmlextras/domparser;1"].
|
|
createInstance(AUS_Ci.nsIDOMParser);
|
|
gXHR.responseXML = parser.parseFromString(gResponseBody, "application/xml");
|
|
} catch (e) {
|
|
}
|
|
var e = { target: gXHR };
|
|
gXHR.onload(e);
|
|
}
|
|
|
|
function check_showUpdateAvailable() {
|
|
do_throw("showUpdateAvailable should not have called openWindow!");
|
|
}
|
|
|
|
var WindowWatcher = {
|
|
openWindow: function(aParent, aUrl, aName, aFeatures, aArgs) {
|
|
check_showUpdateAvailable();
|
|
},
|
|
|
|
QueryInterface: function(aIID) {
|
|
if (aIID.equals(AUS_Ci.nsIWindowWatcher) ||
|
|
aIID.equals(AUS_Ci.nsISupports))
|
|
return this;
|
|
|
|
throw AUS_Cr.NS_ERROR_NO_INTERFACE;
|
|
}
|
|
}
|
|
|
|
var WindowWatcherFactory = {
|
|
createInstance: function createInstance(aOuter, aIID) {
|
|
if (aOuter != null)
|
|
throw AUS_Cr.NS_ERROR_NO_AGGREGATION;
|
|
return WindowWatcher.QueryInterface(aIID);
|
|
}
|
|
};
|
|
|
|
var WindowMediator = {
|
|
getMostRecentWindow: function(aWindowType) {
|
|
return null;
|
|
},
|
|
|
|
QueryInterface: function(aIID) {
|
|
if (aIID.equals(AUS_Ci.nsIWindowMediator) ||
|
|
aIID.equals(AUS_Ci.nsISupports))
|
|
return this;
|
|
|
|
throw AUS_Cr.NS_ERROR_NO_INTERFACE;
|
|
}
|
|
}
|
|
|
|
var WindowMediatorFactory = {
|
|
createInstance: function createInstance(aOuter, aIID) {
|
|
if (aOuter != null)
|
|
throw AUS_Cr.NS_ERROR_NO_AGGREGATION;
|
|
return WindowMediator.QueryInterface(aIID);
|
|
}
|
|
};
|