Bug 1510254 - Remove custom FirefoxRunner subclass, r=gbrown,KWierso
authorJames Graham <james@hoppipolla.co.uk>
Fri, 30 Nov 2018 15:31:46 +0000
changeset 508204 ed149f9cf50a61f1a6f90f3163d89d809414d632
parent 508203 0ffc19c364e82f893b636540c19da0aa6ca36cc2
child 508205 7d17aa7e056119b29b713caa1bd63d575ad2cc56
push id1905
push userffxbld-merge
push dateMon, 21 Jan 2019 12:33:13 +0000
treeherdermozilla-release@c2fca1944d8c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgbrown, KWierso
bugs1510254
milestone65.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1510254 - Remove custom FirefoxRunner subclass, r=gbrown,KWierso This was only being used to set prefs and most prefs are either already set in testing/profiles/[common|unittest|web-platform-tests].js or can be set there so they apply to desktop too. Differential Revision: https://phabricator.services.mozilla.com/D13088
testing/profiles/web-platform/user.js
testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/fennec.py
--- a/testing/profiles/web-platform/user.js
+++ b/testing/profiles/web-platform/user.js
@@ -21,8 +21,16 @@ user_pref("network.proxy.type", 0);
 // gigabytes).
 user_pref("places.history.enabled", false);
 // Suppress automatic safe mode after crashes
 user_pref("toolkit.startup.max_resumed_crashes", -1);
 // Disable antialiasing for the Ahem font.
 user_pref("gfx.font_ahem_antialias_none", true);
 // Disable antiphishing popup
 user_pref("network.http.phishy-userpass-length", 255);
+// Disable safebrowsing components
+user_pref("browser.safebrowsing.blockedURIs.enabled", false);
+user_pref("browser.safebrowsing.downloads.enabled", false);
+user_pref("browser.safebrowsing.passwords.enabled", false);
+user_pref("browser.safebrowsing.malware.enabled", false);
+user_pref("browser.safebrowsing.phishing.enabled", false);
+// Automatically unload beforeunload alerts
+user_pref("dom.disable_beforeunload", true);
--- a/testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/fennec.py
+++ b/testing/web-platform/tests/tools/wptrunner/wptrunner/browsers/fennec.py
@@ -29,71 +29,21 @@ from .firefox import (get_timeout_multip
                               "reftest": "MarionetteRefTestExecutor"},
                  "browser_kwargs": "browser_kwargs",
                  "executor_kwargs": "executor_kwargs",
                  "env_extras": "env_extras",
                  "env_options": "env_options",
                  "run_info_extras": "run_info_extras",
                  "update_properties": "update_properties"}
 
-class FennecProfile(FirefoxProfile):
-    # WPT-specific prefs are set in FennecBrowser.start()
-    FirefoxProfile.preferences.update({
-        # Make sure Shield doesn't hit the network.
-        "app.normandy.api_url": "",
-        # Increase the APZ content response timeout in tests to 1 minute.
-        "apz.content_response_timeout": 60000,
-        # Enable output for dump() and chrome console API
-        "browser.dom.window.dump.enabled": True,
-        "devtools.console.stdout.chrome": True,
-        # Disable safebrowsing components
-        "browser.safebrowsing.blockedURIs.enabled": False,
-        "browser.safebrowsing.downloads.enabled": False,
-        "browser.safebrowsing.passwords.enabled": False,
-        "browser.safebrowsing.malware.enabled": False,
-        "browser.safebrowsing.phishing.enabled": False,
-        # Do not restore the last open set of tabs if the browser has crashed
-        "browser.sessionstore.resume_from_crash": False,
-        # Disable Android snippets
-        "browser.snippets.enabled": False,
-        "browser.snippets.syncPromo.enabled": False,
-        "browser.snippets.firstrunHomepage.enabled": False,
-        # Do not allow background tabs to be zombified, otherwise for tests that
-        # open additional tabs, the test harness tab itself might get unloaded
-        "browser.tabs.disableBackgroundZombification": True,
-        # Disable e10s by default
-        "browser.tabs.remote.autostart": False,
-        # Don't warn when exiting the browser
-        "browser.warnOnQuit": False,
-        # Don't send Firefox health reports to the production server
-        "datareporting.healthreport.about.reportUrl": "http://%(server)s/dummy/abouthealthreport/",
-        # Automatically unload beforeunload alerts
-        "dom.disable_beforeunload": True,
-        # Disable the ProcessHangMonitor
-        "dom.ipc.reportProcessHangs": False,
-        # No slow script dialogs
-        "dom.max_chrome_script_run_time": 0,
-        "dom.max_script_run_time": 0,
-        # Make sure opening about:addons won"t hit the network
-        "extensions.webservice.discoverURL": "http://%(server)s/dummy/discoveryURL",
-        # No hang monitor
-        "hangmonitor.timeout": 0,
-
-        "javascript.options.showInConsole": True,
-        # Ensure blocklist updates don't hit the network
-        "services.settings.server": "http://%(server)s/dummy/blocklist/",
-        # Disable password capture, so that tests that include forms aren"t
-        # influenced by the presence of the persistent doorhanger notification
-        "signon.rememberSignons": False,
-    })
-
 
 def check_args(**kwargs):
     pass
 
+
 def browser_kwargs(test_type, run_info_data, config, **kwargs):
     return {"package_name": kwargs["package_name"],
             "device_serial": kwargs["device_serial"],
             "prefs_root": kwargs["prefs_root"],
             "extra_prefs": kwargs["extra_prefs"],
             "test_type": test_type,
             "debug_info": kwargs["debug_info"],
             "symbols_path": kwargs["symbols_path"],
@@ -181,17 +131,17 @@ class FennecBrowser(FirefoxBrowser):
         env["MOZ_CRASHREPORTER_SHUTDOWN"] = "1"
         env["MOZ_DISABLE_NONLOCAL_CONNECTIONS"] = "1"
         env["STYLO_THREADS"] = str(self.stylo_threads)
         if self.chaos_mode_flags is not None:
             env["MOZ_CHAOSMODE"] = str(self.chaos_mode_flags)
 
         preferences = self.load_prefs()
 
-        self.profile = FennecProfile(preferences=preferences)
+        self.profile = FirefoxProfile(preferences=preferences)
         self.profile.set_preferences({"marionette.port": self.marionette_port,
                                       "dom.disable_open_during_load": False,
                                       "places.history.enabled": False,
                                       "dom.send_after_paint_to_content": True,
                                       "network.preload": True})
 
         if self.install_fonts:
             self.logger.debug("Copying Ahem font to profile")