1
0
mirror of https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git synced 2024-12-20 09:23:08 +00:00

Try and disable Firefox "quick suggest onboarding" thing

Tests that use Firefox started failing recently because Firefox
grew yet another stupid pop-up thing that *might* show on start
up, this appears to be trying to get you to sign up for a
feature called "quick suggest". After half an hour trawling the
relevant code, this is my best guess as to how to turn it off.
Don't know for sure if it works because the thing doesn't pop
up every time, but it at least doesn't make things worse.

Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
Adam Williamson 2022-02-07 12:04:55 -08:00
parent 7945a08271
commit 628c4a5d8f

View File

@ -414,8 +414,15 @@ sub disable_firefox_studies {
# and also disables the password manager stuff so that doesn't
# break password entry:
# https://bugzilla.mozilla.org/show_bug.cgi?id=1635833
# and *also* disables the "quick suggest onboarding dialog"
# (god I am starting to hate this crap):
# https://bugzilla.mozilla.org/show_bug.cgi?id=1703903
assert_script_run 'mkdir -p $(rpm --eval %_libdir)/firefox/distribution';
assert_script_run 'printf \'{"policies": {"DisableFirefoxStudies": true, "OfferToSaveLogins": false}}\' > $(rpm --eval %_libdir)/firefox/distribution/policies.json';
assert_script_run 'mkdir -p $(rpm --eval %_libdir)/firefox/browser/defaults/preferences';
# it's not at all clear from the code which of these actually gets
# used, so we set them all just in case
assert_script_run 'printf "pref(\'browser.urlbar.quicksuggest.shouldShowOnboardingDialog\', false);\npref(\'quickSuggestShouldShowOnboardingDialog\', false);\npref(\'browser.urlbar.quickSuggestShouldShowOnboardingDialog\', false);" > $(rpm --eval %_libdir)/firefox/browser/defaults/preferences/openqa-overrides.js';
}
sub repos_mirrorlist {