Bug 905404 - [mozprofile] Remove all default testing related preferences. r=ahal

All preferences which were previously set for test harnesses are
part of testing/profiles now. As such they can all be removed.

--HG--
extra : rebase_source : 3feaac102f7b8a63ec4f07d84e121f26c49ce3c0
extra : histedit_source : e5b474e75d9f2c372c6439502fa1b30c8727e133
This commit is contained in:
Henrik Skupin 2018-09-05 17:01:17 +02:00
Родитель c8659bd663
Коммит 281acf7f9c
2 изменённых файлов: 13 добавлений и 59 удалений

Просмотреть файл

@ -427,61 +427,22 @@ class Profile(BaseProfile):
class FirefoxProfile(Profile):
"""Specialized Profile subclass for Firefox"""
preferences = { # Don't automatically update the application
'app.update.disabledForTesting': True,
'security.turn_off_all_security_so_that_viruses_can_take_over_this_computer': True,
# Don't restore the last open set of tabs if the browser has crashed
'browser.sessionstore.resume_from_crash': False,
# Don't check for the default web browser during startup
'browser.shell.checkDefaultBrowser': False,
# Don't warn on exit when multiple tabs are open
'browser.tabs.warnOnClose': False,
# Don't warn when exiting the browser
'browser.warnOnQuit': False,
# Don't send Firefox health reports to the production server
'datareporting.healthreport.documentServerURI': 'http://%(server)s/healthreport/',
# Skip data reporting policy notifications
'datareporting.policy.dataSubmissionPolicyBypassNotification': True,
# Only install add-ons from the profile and the application scope
# Also ensure that those are not getting disabled.
# see: https://developer.mozilla.org/en/Installing_extensions
'extensions.enabledScopes': 5,
'extensions.autoDisableScopes': 10,
# Don't send the list of installed addons to AMO
'extensions.getAddons.cache.enabled': False,
# Don't install distribution add-ons from the app folder
'extensions.installDistroAddons': False,
# Don't automatically update add-ons
'extensions.update.enabled': False,
# Don't open a dialog to show available add-on updates
'extensions.update.notifyUser': False,
# Enable test mode to run multiple tests in parallel
'focusmanager.testmode': True,
# Enable test mode to not raise an OS level dialog for location sharing
'geo.provider.testing': True,
# Suppress delay for main action in popup notifications
'security.notification_enable_delay': 0,
# Suppress automatic safe mode after crashes
'toolkit.startup.max_resumed_crashes': -1,
# Don't send Telemetry reports to the production server. This is
# needed as Telemetry sends pings also if FHR upload is enabled.
'toolkit.telemetry.server': 'http://%(server)s/telemetry-dummy/',
}
preferences = {}
class ThunderbirdProfile(Profile):
"""Specialized Profile subclass for Thunderbird"""
preferences = {'extensions.update.enabled': False,
'extensions.update.notifyUser': False,
'browser.shell.checkDefaultBrowser': False,
'browser.tabs.warnOnClose': False,
'browser.warnOnQuit': False,
'browser.sessionstore.resume_from_crash': False,
# prevents the 'new e-mail address' wizard on new profile
'mail.provider.enabled': False,
}
preferences = {
'extensions.update.enabled': False,
'extensions.update.notifyUser': False,
'browser.shell.checkDefaultBrowser': False,
'browser.tabs.warnOnClose': False,
'browser.warnOnQuit': False,
'browser.sessionstore.resume_from_crash': False,
# prevents the 'new e-mail address' wizard on new profile
'mail.provider.enabled': False,
}
class ChromeProfile(BaseProfile):

Просмотреть файл

@ -17,14 +17,8 @@ here = os.path.dirname(os.path.abspath(__file__))
def test_profileprint(tmpdir):
"""
test the summary function
"""
keys = set(['Files', 'Path', 'user.js'])
ff_prefs = mozprofile.FirefoxProfile.preferences # shorthand
pref_string = '\n'.join(['%s: %s' % (key, ff_prefs[key])
for key in sorted(ff_prefs.keys())])
"""Test the summary function."""
keys = set(['Files', 'Path'])
tmpdir = tmpdir.strpath
profile = mozprofile.FirefoxProfile(tmpdir)
@ -33,7 +27,6 @@ def test_profileprint(tmpdir):
assert parts['Path'] == tmpdir
assert set(parts.keys()) == keys
assert pref_string == parts['user.js'].strip()
def test_str_cast():