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

Unified Diff: ios/public/test/test_keyed_service_provider.cc

Issue 1158223003: [iOS] Add FakeSyncService and factory for testing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review comments Created 5 years, 6 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
« no previous file with comments | « ios/public/test/test_keyed_service_provider.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/public/test/test_keyed_service_provider.cc
diff --git a/ios/public/test/test_keyed_service_provider.cc b/ios/public/test/test_keyed_service_provider.cc
new file mode 100644
index 0000000000000000000000000000000000000000..053d47e4180fa516550d1c3a9d4b77d7f1985c9a
--- /dev/null
+++ b/ios/public/test/test_keyed_service_provider.cc
@@ -0,0 +1,29 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "ios/public/test/test_keyed_service_provider.h"
+
+#include "components/sync_driver/fake_sync_service.h"
+#include "ios/public/provider/chrome/browser/browser_state/chrome_browser_state.h"
+#include "ios/public/test/fake_sync_service_factory.h"
+
+namespace ios {
+
+TestKeyedServiceProvider::TestKeyedServiceProvider() {
+}
+
+TestKeyedServiceProvider::~TestKeyedServiceProvider() {
+}
+
+KeyedServiceBaseFactory* TestKeyedServiceProvider::GetSyncServiceFactory() {
+ return FakeSyncServiceFactory::GetInstance();
+}
+
+sync_driver::SyncService*
+TestKeyedServiceProvider::GetSyncServiceForBrowserState(
+ ChromeBrowserState* browser_state) {
+ return FakeSyncServiceFactory::GetForBrowserState(browser_state);
+}
+
+} // namespace ios
« no previous file with comments | « ios/public/test/test_keyed_service_provider.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698