From 1faa130d15bbd753ed3e6270efa37c3e8f69f88b Mon Sep 17 00:00:00 2001 From: Matthew Noorenberghe Date: Thu, 29 Aug 2019 15:20:53 +0000 Subject: [PATCH] Bug 1577180 - Get a profile before accessing BrowserGlue in test_getPotentialBreachesByLoginGUID.js. r=jaws I'm not sure of the exact cause since that would require doing a local Windows beta build and the getService error doesn't indicate what failed inside the component. I mostly guessed that this was the problem by looking at other tests which do the same thing. Differential Revision: https://phabricator.services.mozilla.com/D43899 --HG-- extra : moz-landing-system : lando --- .../tests/unit/test_getPotentialBreachesByLoginGUID.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/browser/components/aboutlogins/tests/unit/test_getPotentialBreachesByLoginGUID.js b/browser/components/aboutlogins/tests/unit/test_getPotentialBreachesByLoginGUID.js index 94422665a37a..6af6f1abacde 100644 --- a/browser/components/aboutlogins/tests/unit/test_getPotentialBreachesByLoginGUID.js +++ b/browser/components/aboutlogins/tests/unit/test_getPotentialBreachesByLoginGUID.js @@ -8,6 +8,10 @@ const { RemoteSettings } = ChromeUtils.import( "resource://services-settings/remote-settings.js" ); const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm"); + +// Initializing BrowserGlue requires a profile on Windows. +do_get_profile(); + const gBrowserGlue = Cc["@mozilla.org/browser/browserglue;1"].getService( Ci.nsIObserver );