Can't change Firefox preferences of type Boolean
You can set a preference to a Boolean value, but it only works on new prefs. It can't change the value of an existing Firefox pref.
e.g.
preferences={'app.normandy.first_run': True, 'app.normandy.first_run1': True }
Result in prefs.js:
user_pref("app.normandy.first_run", false);
user_pref("app.normandy.first_run1", true);
(Migrated from here.)
Needs more investigation. Not sure if the issue is as above, or if Fx is overwriting whatever we set.
How does mozrunner successfully make all the settings it applies stick?
Actually, I'm not sure that we have proven a bug in Iris or mozprofile here. The mechanism that mozprofile uses adds entries to the user.js file in the profile. We can see that part is working just by opening that file. However, upon opening prefs.js - which is written back to disk by Firefox after startup - we see that some values don't "stick," but that only represents the state of Firefox when it quit.
Give me an example of a Boolean pref that you need to work on one of the tests. We can run this manually by adding it to an empty profile's user.js file. Then, we can examine the outcome and see if Firefox respected the value, and/or wrote it to prefs.js. If it doesn't work at all, then that could be a Firefox bug.
browser.search.widget.inNavBar = true is a config that would be useful in many of the search tests. As of now, tests are setting this through the about:config UI.
I tried adding this to user.js like so:
user_pref("browser.search.widget.inNavBar", true);
But when Firefox opened and I checked about:config, it was still set to false. So, it appears that there are things we cannot set in a profile before launching Firefox. This appears to be a Firefox issue. Would be worth searching Bugzilla to see if it's known.
See https://bugzilla.mozilla.org/show_bug.cgi?id=1543752 . There is discussion about what is going on with these files.
This looks bad for us. I imagine other people rely on mozprofile and would be affected by this change.