We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 915b2f8 commit 218bc97Copy full SHA for 218bc97
browser/components/distribution.sys.mjs
@@ -53,7 +53,14 @@ DistributionCustomizer.prototype = {
53
PREF_CACHED_FILE_APPVERSION,
54
"unknown"
55
);
56
- if (knownForVersion == AppConstants.MOZ_APP_VERSION) {
+ // StartupCacheInfo isn't available in xpcshell tests.
57
+ if (
58
+ knownForVersion == AppConstants.MOZ_APP_VERSION &&
59
+ (Cu.isInAutomation ||
60
+ Cc["@mozilla.org/startupcacheinfo;1"].getService(
61
+ Ci.nsIStartupCacheInfo
62
+ ).FoundDiskCacheOnInit)
63
+ ) {
64
return Services.prefs.getBoolPref(PREF_CACHED_FILE_EXISTENCE);
65
}
66
0 commit comments