Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(608)

Unified Diff: chrome/browser/chromeos/ownership/fake_owner_settings_service.h

Issue 1019283004: Switch to direct use of OwnerSettingsServiceChromeOS::Set() in tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Replace inheritance with composition. Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/ownership/fake_owner_settings_service.h
diff --git a/chrome/browser/chromeos/ownership/fake_owner_settings_service.h b/chrome/browser/chromeos/ownership/fake_owner_settings_service.h
index bed4d066792373a170db9a4dadaa7a41f08ccfaf..3f785c1d7aae0b5d76b9fc8749c47d821651936f 100644
--- a/chrome/browser/chromeos/ownership/fake_owner_settings_service.h
+++ b/chrome/browser/chromeos/ownership/fake_owner_settings_service.h
@@ -17,11 +17,15 @@ class OwnerKeyUtil;
namespace chromeos {
+class StubCrosSettingsProvider;
+
class FakeOwnerSettingsService : public OwnerSettingsServiceChromeOS {
public:
+ explicit FakeOwnerSettingsService(Profile* profile);
FakeOwnerSettingsService(
Profile* profile,
- const scoped_refptr<ownership::OwnerKeyUtil>& owner_key_util);
+ const scoped_refptr<ownership::OwnerKeyUtil>& owner_key_util,
+ StubCrosSettingsProvider* provider);
~FakeOwnerSettingsService() override;
void set_set_management_settings_result(bool success) {
@@ -36,10 +40,12 @@ class FakeOwnerSettingsService : public OwnerSettingsServiceChromeOS {
void SetManagementSettings(
const ManagementSettings& settings,
const OnManagementSettingsSetCallback& callback) override;
+ bool Set(const std::string& setting, const base::Value& value) override;
private:
bool set_management_settings_result_;
ManagementSettings last_settings_;
+ StubCrosSettingsProvider* settings_provider_;
DISALLOW_COPY_AND_ASSIGN(FakeOwnerSettingsService);
};

Powered by Google App Engine
This is Rietveld 408576698