Bug 1572687 - [marionette] Disable the GFX sanity window. r=webdriver-reviewers,maja_zf
authorHenrik Skupin <mail@hskupin.info>
Mon, 12 Aug 2019 14:21:44 +0000
changeset 487465 2b3e775a99cb38b9243cb816075c8a8f027114d7
parent 487464 5a291331e67a968824f787c6c19235e412272623
child 487466 0c1fa26f2f67749fda7cfbd6ab2f3f61334f6925
push id113879
push usermalexandru@mozilla.com
push dateMon, 12 Aug 2019 22:02:50 +0000
treeherdermozilla-inbound@1ca06cd3e226 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerswebdriver-reviewers, maja_zf
bugs1572687
milestone70.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 1572687 - [marionette] Disable the GFX sanity window. r=webdriver-reviewers,maja_zf Differential Revision: https://phabricator.services.mozilla.com/D41357
testing/marionette/client/marionette_driver/geckoinstance.py
testing/marionette/harness/marionette_harness/tests/unit/test_prefs.py
--- a/testing/marionette/client/marionette_driver/geckoinstance.py
+++ b/testing/marionette/client/marionette_driver/geckoinstance.py
@@ -117,16 +117,19 @@ class GeckoInstance(object):
         # Do not automatically switch between offline and online
         "network.manage-offline-status": False,
         # Make sure SNTP requests don't hit the network
         "network.sntp.pools": "%(server)s",
 
         # Privacy and Tracking Protection
         "privacy.trackingprotection.enabled": False,
 
+        # Disable the GFX sanity window
+        "sanity-test.running": True,
+
         # Don't do network connections for mitm priming
         "security.certerrors.mitm.priming.enabled": False,
 
         # Tests don't wait for the notification button security delay
         "security.notification_enable_delay": 0,
 
         # Ensure blocklist updates don't hit the network
         "services.settings.server": "http://%(server)s/dummy/blocklist/",
--- a/testing/marionette/harness/marionette_harness/tests/unit/test_prefs.py
+++ b/testing/marionette/harness/marionette_harness/tests/unit/test_prefs.py
@@ -24,29 +24,34 @@ class TestPreferences(MarionetteTestCase
 
     def tearDown(self):
         for pref in self.prefs.values():
             self.marionette.clear_pref(pref)
 
         super(TestPreferences, self).tearDown()
 
     def test_gecko_instance_preferences(self):
+        ignored_prefs = [
+            "sanity-test.running",  # will be reset during each startup
+        ]
         required_prefs = geckoinstance.GeckoInstance.required_prefs
 
         for key, value in required_prefs.iteritems():
             # The extensions.shield-recipe-client.* prefs branch
             # is as of Firefox 60 migrated to app.normandy.*.
             #
             # This is a workaround that can be removed together
             # with extensions.shield-recipe-client.api_url.
             if key == "extensions.shield-recipe-client.api_url":
                 self.assertEqual(self.marionette.get_pref("app.normandy.api_url"), value)
             else:
-                self.assertEqual(self.marionette.get_pref(key), value,
-                                 "Preference {} hasn't been set to {}".format(key, repr(value)))
+                if key not in ignored_prefs:
+                    self.assertEqual(
+                        self.marionette.get_pref(key), value,
+                        "Preference {} hasn't been set to {}".format(key, repr(value)))
 
     @skip_if_mobile("Only runnable with Firefox")
     def test_desktop_instance_preferences(self):
         required_prefs = geckoinstance.DesktopInstance.desktop_prefs
 
         for key, value in required_prefs.iteritems():
             if key in ["browser.tabs.remote.autostart"]:
                 return