diff options
author | sdefresne <sdefresne@chromium.org> | 2015-09-18 02:47:51 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-09-18 09:48:29 +0000 |
commit | 50c1e529587af459c14828ebe48d2e018d4b8e98 (patch) | |
tree | fce899626a1def4c171c4e348101d67746058eca /chrome/test/base/testing_profile.h | |
parent | c956799bbab4a8ef3c3f223f5179847a89d2eda1 (diff) | |
download | chromium_src-50c1e529587af459c14828ebe48d2e018d4b8e98.zip chromium_src-50c1e529587af459c14828ebe48d2e018d4b8e98.tar.gz chromium_src-50c1e529587af459c14828ebe48d2e018d4b8e98.tar.bz2 |
Add syncable_prefs namespace.
Move all the code in the syncable_prefs components into the namespace
syncable_prefs and fix usage.
Change automated with tools/git/mffr.py with manual fixes for the
class forward-declaration.
BUG=520542
TBR=jochen@chromium.org
Review URL: https://codereview.chromium.org/1353913003
Cr-Commit-Position: refs/heads/master@{#349638}
Diffstat (limited to 'chrome/test/base/testing_profile.h')
-rw-r--r-- | chrome/test/base/testing_profile.h | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/chrome/test/base/testing_profile.h b/chrome/test/base/testing_profile.h index c941cd8..6663fa5 100644 --- a/chrome/test/base/testing_profile.h +++ b/chrome/test/base/testing_profile.h @@ -16,6 +16,10 @@ #include "components/domain_reliability/clear_mode.h" #include "components/keyed_service/content/browser_context_keyed_service_factory.h" +class BrowserContextDependencyManager; +class ExtensionSpecialStoragePolicy; +class HostContentSettingsMap; + namespace content { class MockResourceContext; class SSLHostStateDelegate; @@ -37,11 +41,10 @@ namespace storage { class SpecialStoragePolicy; } -class BrowserContextDependencyManager; -class ExtensionSpecialStoragePolicy; -class HostContentSettingsMap; +namespace syncable_prefs { class PrefServiceSyncable; class TestingPrefServiceSyncable; +} class TestingProfile : public Profile { public: @@ -94,7 +97,7 @@ class TestingProfile : public Profile { void SetPath(const base::FilePath& path); // Sets the PrefService to be used by this profile. - void SetPrefService(scoped_ptr<PrefServiceSyncable> prefs); + void SetPrefService(scoped_ptr<syncable_prefs::PrefServiceSyncable> prefs); // Makes the Profile being built a guest profile. void SetGuestSession(); @@ -119,7 +122,7 @@ class TestingProfile : public Profile { bool build_called_; // Various staging variables where values are held until Build() is invoked. - scoped_ptr<PrefServiceSyncable> pref_service_; + scoped_ptr<syncable_prefs::PrefServiceSyncable> pref_service_; #if defined(ENABLE_EXTENSIONS) scoped_refptr<ExtensionSpecialStoragePolicy> extension_policy_; #endif @@ -153,7 +156,7 @@ class TestingProfile : public Profile { #if defined(ENABLE_EXTENSIONS) scoped_refptr<ExtensionSpecialStoragePolicy> extension_policy, #endif - scoped_ptr<PrefServiceSyncable> prefs, + scoped_ptr<syncable_prefs::PrefServiceSyncable> prefs, TestingProfile* parent, bool guest_session, const std::string& supervised_user_id, @@ -196,7 +199,7 @@ class TestingProfile : public Profile { // Allow setting a profile as Guest after-the-fact to simplify some tests. void SetGuestSession(bool guest); - TestingPrefServiceSyncable* GetTestingPrefService(); + syncable_prefs::TestingPrefServiceSyncable* GetTestingPrefService(); // Called on the parent of an incognito |profile|. Usually called from the // constructor of an incognito TestingProfile, but can also be used by tests @@ -321,9 +324,9 @@ class TestingProfile : public Profile { protected: base::Time start_time_; - scoped_ptr<PrefServiceSyncable> prefs_; + scoped_ptr<syncable_prefs::PrefServiceSyncable> prefs_; // ref only for right type, lifecycle is managed by prefs_ - TestingPrefServiceSyncable* testing_prefs_; + syncable_prefs::TestingPrefServiceSyncable* testing_prefs_; private: // Creates a temporary directory for use by this profile. |