[Extensions] Make ExtensionPrefsHelper a keyed service. This is another step in disentangling the Preference API, the FontSettings API, and the Settings Overrides API. It moves some helper functions from the PreferencesAPI class to a keyed service in /extensions/browser. This is a reland of an earlier CL with some important changes: 1. The PreferenceAPI is not created in unit tests, but in the original version of this CL, the ExtensionPrefsHelper instance was created. This led to flakiness on Mac builds. This CL follows the original pattern for the PreferenceAPI so the ExtensionPrefsHelper class is not created in unit tests. 2. In the original CL, there were changes to a ExtensionMessageBubbleTest unit test to populate an underlying data structure that the ExtensionPrefsHelper relies on. Since it's no longer being created in unit tests, the changes to populate that data structure are removed. The original CL, which was reverted, is here: commit 32fe4701ea9b87e3f7d0a51a99cb0a202a1273b8. With the original CL, ExtensionMessageBubbleTest.SettingsApiControllerTest was quite flaky on the mac-rel bot. With this CL, the test passed 3000 iterations without any flakes. LOW_COVERAGE_REASON=Seems related to recent code added for Lacros. Bug: 883570 Change-Id: I85e4919360bbf6660f022ba161e453ebf1ffe814 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3988363 Commit-Queue: David Bertoni <dbertoni@chromium.org> Reviewed-by: Emilia Paz <emiliapaz@chromium.org> Cr-Commit-Position: refs/heads/main@{#1067616}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone! Instead, follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.