Bug 1400357 - Whitelist maximize.svg in browser_startup_images. r=florian draft
authorJohann Hofmann <jhofmann@mozilla.com>
Fri, 22 Sep 2017 11:23:22 +0200
changeset 669114 b92cbd14b873bf8aa0d70e27b140cb0f1a946b74
parent 669023 2cd3752963fc8f24f7c202687eab55e83222f608
child 732857 d547ca6b8d2c10a4056ab18cd0c6ad7f1b9c2ce9
push id81215
push userbmo:jhofmann@mozilla.com
push dateFri, 22 Sep 2017 14:32:12 +0000
reviewersflorian
bugs1400357
milestone58.0a1
Bug 1400357 - Whitelist maximize.svg in browser_startup_images. r=florian There have been changes to our Windows infrastructure that cause the window to be maximized when running tests so the maximize.svg/restore.svg combination will show restore instead of maximize, though maximize is still loaded. I think it could be prevented by trying to set the sizemode attribute a little earlier or not defaulting to maximize in the stylesheet, but I don't think that's a necessary optimization at this point. We can just whitelist it. I also set the intermittentShown flag in case the Windows machines go back to non-maximized windows. MozReview-Commit-ID: Gwi0jRBBtGg
browser/base/content/test/performance/browser_startup_images.js
browser/base/content/test/performance/hidpi/browser.ini
--- a/browser/base/content/test/performance/browser_startup_images.js
+++ b/browser/base/content/test/performance/browser_startup_images.js
@@ -29,16 +29,18 @@ const whitelist = [
     file: "chrome://browser/skin/tabbrowser/tab-overflow-indicator.png",
     platforms: ["linux", "win", "macosx"],
   },
 
   {
     file: "chrome://browser/skin/places/toolbarDropMarker.png",
     platforms: ["linux", "win", "macosx"],
   },
+
+  // Bug 1363040
   {
     file: "chrome://browser/skin/tracking-protection-16.svg#enabled",
     platforms: ["linux", "win", "macosx"],
   },
 
   {
     file: "chrome://browser/skin/tabbrowser/tabDragIndicator.png",
     hidpi: "chrome://browser/skin/tabbrowser/tabDragIndicator@2x.png",
@@ -66,16 +68,26 @@ const whitelist = [
     file: "chrome://browser/skin/chevron.svg",
     platforms: ["win", "linux", "macosx"],
   },
 
   {
     file: "chrome://global/skin/icons/resizer.png",
     platforms: ["win"],
   },
+
+  {
+    file: "chrome://browser/skin/window-controls/maximize.svg",
+    platforms: ["win"],
+    // This is to prevent perma-fails in case Windows machines
+    // go back to running tests in non-maximized windows.
+    intermittentShown: ["win"],
+    // This file is not loaded on Windows 7/8.
+    intermittentNotLoaded: ["win"],
+  },
 ];
 
 add_task(async function() {
   if (!AppConstants.DEBUG) {
     ok(false, "You need to run this test on a debug build.");
   }
 
   let startupRecorder = Cc["@mozilla.org/test/startuprecorder;1"].getService().wrappedJSObject;
--- a/browser/base/content/test/performance/hidpi/browser.ini
+++ b/browser/base/content/test/performance/hidpi/browser.ini
@@ -1,6 +1,6 @@
 [DEFAULT]
 prefs =
   layout.css.devPixelsPerPx='2'
 
 [../browser_startup_images.js]
-skip-if = !debug || (os == 'win' && (os_version == '6.1' || os_version == '10.0'))  # hidpi results in the toolbar overflowing on Win 7; fails on Win 10 (bug 1400357)
+skip-if = !debug || (os == 'win' && (os_version == '6.1'))  # hidpi results in the toolbar overflowing on Win 7