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

Unified Diff: chrome/browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc

Issue 14053004: Add ManagedUserSettings Sync data type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 7 years, 8 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 | « chrome/browser/sync/sync_prefs.cc ('k') | chrome/browser/ui/webui/sync_setup_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc
diff --git a/chrome/browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc b/chrome/browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc
new file mode 100644
index 0000000000000000000000000000000000000000..03307ded0ef39e45f535e36a4b42ab4ad1aa691d
--- /dev/null
+++ b/chrome/browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc
@@ -0,0 +1,28 @@
+// Copyright (c) 2013 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 "base/prefs/pref_service.h"
+#include "chrome/browser/managed_mode/managed_user_service.h"
+#include "chrome/browser/managed_mode/managed_user_service_factory.h"
+#include "chrome/browser/profiles/profile.h"
+#include "chrome/browser/sync/profile_sync_service_harness.h"
+#include "chrome/browser/sync/test/integration/sync_test.h"
+#include "chrome/common/pref_names.h"
+
+class SingleClientManagedUserSettingsSyncTest : public SyncTest {
+ public:
+ SingleClientManagedUserSettingsSyncTest() : SyncTest(SINGLE_CLIENT) {}
+
+ virtual ~SingleClientManagedUserSettingsSyncTest() {}
+};
+
+IN_PROC_BROWSER_TEST_F(SingleClientManagedUserSettingsSyncTest, Sanity) {
+ ASSERT_TRUE(SetupClients());
+ for (int i = 0; i < num_clients(); ++i) {
+ Profile* profile = GetProfile(i);
+ profile->GetPrefs()->SetBoolean(prefs::kProfileIsManaged, true);
+ ManagedUserServiceFactory::GetForProfile(profile)->Init();
+ }
+ ASSERT_TRUE(SetupSync());
+}
« no previous file with comments | « chrome/browser/sync/sync_prefs.cc ('k') | chrome/browser/ui/webui/sync_setup_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698