From 086c044dc34dfc0f74fbe41f4ecb402b2cd34884 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 03:13:33 +0200 Subject: Merging upstream version 125.0.1. Signed-off-by: Daniel Baumann --- .../browser/browser_policy_allowfileselectiondialogs.js | 2 +- .../tests/xpcshell/test_policy_search_engine.js | 2 +- .../tests/xpcshell/test_simple_pref_policies.js | 13 +++++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) (limited to 'browser/components/enterprisepolicies/tests') diff --git a/browser/components/enterprisepolicies/tests/browser/browser_policy_allowfileselectiondialogs.js b/browser/components/enterprisepolicies/tests/browser/browser_policy_allowfileselectiondialogs.js index 94f6bba631..4ba4a7cf25 100644 --- a/browser/components/enterprisepolicies/tests/browser/browser_policy_allowfileselectiondialogs.js +++ b/browser/components/enterprisepolicies/tests/browser/browser_policy_allowfileselectiondialogs.js @@ -154,7 +154,7 @@ add_task(async function test_cancel_event() { add_task(async function test_nsIFilePicker_open() { let picker = Cc["@mozilla.org/filepicker;1"].createInstance(Ci.nsIFilePicker); - picker.init(window, "", Ci.nsIFilePicker.modeSave); + picker.init(window.browsingContext, "", Ci.nsIFilePicker.modeSave); let result = await new Promise(resolve => picker.open(res => resolve(res))); diff --git a/browser/components/enterprisepolicies/tests/xpcshell/test_policy_search_engine.js b/browser/components/enterprisepolicies/tests/xpcshell/test_policy_search_engine.js index 5c602442f2..c8eb29982d 100644 --- a/browser/components/enterprisepolicies/tests/xpcshell/test_policy_search_engine.js +++ b/browser/components/enterprisepolicies/tests/xpcshell/test_policy_search_engine.js @@ -189,7 +189,7 @@ add_task(async function test_install_and_remove() { Assert.notEqual(engine, null, "Specified search engine should be installed"); Assert.equal( - engine.wrappedJSObject.getIconURL(), + await engine.wrappedJSObject.getIconURL(), iconURL, "Icon should be present" ); diff --git a/browser/components/enterprisepolicies/tests/xpcshell/test_simple_pref_policies.js b/browser/components/enterprisepolicies/tests/xpcshell/test_simple_pref_policies.js index 8ef8b831ef..82caee16a7 100644 --- a/browser/components/enterprisepolicies/tests/xpcshell/test_simple_pref_policies.js +++ b/browser/components/enterprisepolicies/tests/xpcshell/test_simple_pref_policies.js @@ -1032,6 +1032,19 @@ const POLICIES_TESTS = [ "browser.newtabpage.activity-stream.asrouter.userprefs.cfr.features": true, }, }, + + // POLICY: AutofillAddressEnabled, AutofillCreditCardEnabled + + { + policies: { + AutofillAddressEnabled: false, + AutofillCreditCardEnabled: false, + }, + lockedPrefs: { + "extensions.formautofill.addresses.enabled": false, + "extensions.formautofill.creditCards.enabled": false, + }, + }, ]; add_task(async function test_policy_simple_prefs() { -- cgit v1.2.3