| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <string> | 5 #include <string> |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/json/json_writer.h" | 8 #include "base/json/json_writer.h" |
| 9 #include "base/macros.h" |
| 9 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
| 10 #include "chrome/browser/supervised_user/legacy/supervised_user_shared_settings_
service.h" | 11 #include "chrome/browser/supervised_user/legacy/supervised_user_shared_settings_
service.h" |
| 11 #include "chrome/common/pref_names.h" | 12 #include "chrome/common/pref_names.h" |
| 12 #include "chrome/test/base/testing_profile.h" | 13 #include "chrome/test/base/testing_profile.h" |
| 13 #include "content/public/test/test_browser_thread_bundle.h" | 14 #include "content/public/test/test_browser_thread_bundle.h" |
| 14 #include "sync/api/fake_sync_change_processor.h" | 15 #include "sync/api/fake_sync_change_processor.h" |
| 15 #include "sync/api/sync_change.h" | 16 #include "sync/api/sync_change.h" |
| 16 #include "sync/api/sync_change_processor_wrapper_for_test.h" | 17 #include "sync/api/sync_change_processor_wrapper_for_test.h" |
| 17 #include "sync/api/sync_error_factory_mock.h" | 18 #include "sync/api/sync_error_factory_mock.h" |
| 18 #include "sync/protocol/sync.pb.h" | 19 #include "sync/protocol/sync.pb.h" |
| (...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 settings_service_.GetAllSyncData(SUPERVISED_USER_SHARED_SETTINGS).size()); | 266 settings_service_.GetAllSyncData(SUPERVISED_USER_SHARED_SETTINGS).size()); |
| 266 EXPECT_EQ(ToJson(&name), | 267 EXPECT_EQ(ToJson(&name), |
| 267 ToJson(settings_service_.GetValue(kIdA, "name"))); | 268 ToJson(settings_service_.GetValue(kIdA, "name"))); |
| 268 EXPECT_EQ(ToJson(&age), ToJson(settings_service_.GetValue(kIdA, "age"))); | 269 EXPECT_EQ(ToJson(&age), ToJson(settings_service_.GetValue(kIdA, "age"))); |
| 269 EXPECT_EQ(ToJson(&bar), ToJson(settings_service_.GetValue(kIdB, "foo"))); | 270 EXPECT_EQ(ToJson(&bar), ToJson(settings_service_.GetValue(kIdB, "foo"))); |
| 270 EXPECT_EQ(ToJson(&blurp), ToJson(settings_service_.GetValue(kIdC, "baz"))); | 271 EXPECT_EQ(ToJson(&blurp), ToJson(settings_service_.GetValue(kIdC, "baz"))); |
| 271 EXPECT_FALSE(settings_service_.GetValue(kIdA, "foo")); | 272 EXPECT_FALSE(settings_service_.GetValue(kIdA, "foo")); |
| 272 EXPECT_FALSE(settings_service_.GetValue(kIdB, "name")); | 273 EXPECT_FALSE(settings_service_.GetValue(kIdB, "name")); |
| 273 EXPECT_FALSE(settings_service_.GetValue(kIdC, "name")); | 274 EXPECT_FALSE(settings_service_.GetValue(kIdC, "name")); |
| 274 } | 275 } |
| OLD | NEW |