Bug 1555389: Expect default theme to be inactive on dev edition. r=aswan a=test-only
authorKris Maglione <maglione.k@gmail.com>
Wed, 29 May 2019 11:03:33 -0700
changeset 536755 5126c82f6b389f2c33b21188a9574585c20afba7
parent 536754 49a329216f65a28acdcaa77729030d7b22fadfb5
child 536756 4d784df0e46e10e6c542f8c81372cc43efd4357a
push id2082
push userffxbld-merge
push dateMon, 01 Jul 2019 08:34:18 +0000
treeherdermozilla-release@2fb19d0466d2 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaswan, test-only
bugs1555389
milestone68.0
Bug 1555389: Expect default theme to be inactive on dev edition. r=aswan a=test-only Differential Revision: https://phabricator.services.mozilla.com/D33056
toolkit/mozapps/extensions/test/mochitest/test_default_theme.html
--- a/toolkit/mozapps/extensions/test/mochitest/test_default_theme.html
+++ b/toolkit/mozapps/extensions/test/mochitest/test_default_theme.html
@@ -8,21 +8,26 @@
   <link rel="stylesheet" href="chrome://mochikit/contents/tests/SimpleTest/test.css">
 </head>
 <body>
 
 <script>
 "use strict";
 
 const {AddonManager} = ChromeUtils.import("resource://gre/modules/AddonManager.jsm");
+const {AppConstants} = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 
 add_task(async function() {
   let addon = await AddonManager.getAddonByID("default-theme@mozilla.org");
 
+  // Dev edition uses a different default theme on desktop.
+  const expectActive = (!AppConstants.MOZ_DEV_EDITION ||
+                        AppConstants.MOZ_BUILD_APP !== "browser");
+
   ok(addon != null, "Default theme exists");
   is(addon.type, "theme", "Add-on type is correct");
-  is(addon.isActive, true, "Add-on is active");
+  is(addon.isActive, expectActive, "Add-on is active?");
   is(addon.hidden, false, "Add-on is not hidden");
 });
 
 </script>
 </body>
 </html>