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

Side by Side Diff: components/sync/driver/sync_policy_handler_unittest.cc

Issue 2395533003: [Sync] Move some things from driver to base. (Closed)
Patch Set: Rebase. Created 4 years, 2 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 unified diff | Download patch
« no previous file with comments | « components/sync/driver/sync_policy_handler.cc ('k') | components/sync/driver/sync_prefs.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/sync/driver/sync_policy_handler.h" 5 #include "components/sync/driver/sync_policy_handler.h"
6 6
7 #include "base/memory/ptr_util.h" 7 #include "base/memory/ptr_util.h"
8 #include "base/values.h" 8 #include "base/values.h"
9 #include "components/policy/core/common/policy_map.h" 9 #include "components/policy/core/common/policy_map.h"
10 #include "components/policy/core/common/policy_types.h" 10 #include "components/policy/core/common/policy_types.h"
11 #include "components/policy/policy_constants.h" 11 #include "components/policy/policy_constants.h"
12 #include "components/prefs/pref_value_map.h" 12 #include "components/prefs/pref_value_map.h"
13 #include "components/sync/driver/pref_names.h" 13 #include "components/sync/base/pref_names.h"
14 #include "testing/gtest/include/gtest/gtest.h" 14 #include "testing/gtest/include/gtest/gtest.h"
15 15
16 namespace syncer { 16 namespace syncer {
17 17
18 // Test cases for the Sync policy setting. 18 // Test cases for the Sync policy setting.
19 class SyncPolicyHandlerTest : public testing::Test {}; 19 class SyncPolicyHandlerTest : public testing::Test {};
20 20
21 TEST_F(SyncPolicyHandlerTest, Default) { 21 TEST_F(SyncPolicyHandlerTest, Default) {
22 policy::PolicyMap policy; 22 policy::PolicyMap policy;
23 SyncPolicyHandler handler; 23 SyncPolicyHandler handler;
(...skipping 28 matching lines...) Expand all
52 const base::Value* value = NULL; 52 const base::Value* value = NULL;
53 EXPECT_TRUE(prefs.GetValue(prefs::kSyncManaged, &value)); 53 EXPECT_TRUE(prefs.GetValue(prefs::kSyncManaged, &value));
54 ASSERT_TRUE(value); 54 ASSERT_TRUE(value);
55 bool sync_managed = false; 55 bool sync_managed = false;
56 bool result = value->GetAsBoolean(&sync_managed); 56 bool result = value->GetAsBoolean(&sync_managed);
57 ASSERT_TRUE(result); 57 ASSERT_TRUE(result);
58 EXPECT_TRUE(sync_managed); 58 EXPECT_TRUE(sync_managed);
59 } 59 }
60 60
61 } // namespace syncer 61 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/driver/sync_policy_handler.cc ('k') | components/sync/driver/sync_prefs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698