| OLD | NEW |
| 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 <string> | 5 #include <string> |
| 6 | 6 |
| 7 #include "base/json/json_string_value_serializer.h" | 7 #include "base/json/json_string_value_serializer.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/time/time.h" | 9 #include "base/time/time.h" |
| 10 #include "base/values.h" | 10 #include "base/values.h" |
| 11 #include "chrome/browser/prefs/pref_service_syncable_util.h" | 11 #include "chrome/browser/prefs/pref_service_syncable_util.h" |
| 12 #include "chrome/browser/prefs/synced_pref_change_registrar.h" | |
| 13 #include "chrome/browser/ui/browser.h" | 12 #include "chrome/browser/ui/browser.h" |
| 14 #include "chrome/common/pref_names.h" | 13 #include "chrome/common/pref_names.h" |
| 15 #include "chrome/test/base/in_process_browser_test.h" | 14 #include "chrome/test/base/in_process_browser_test.h" |
| 16 #include "chrome/test/base/testing_pref_service_syncable.h" | |
| 17 #include "chrome/test/base/testing_profile.h" | 15 #include "chrome/test/base/testing_profile.h" |
| 16 #include "components/syncable_prefs/synced_pref_change_registrar.h" |
| 17 #include "components/syncable_prefs/testing_pref_service_syncable.h" |
| 18 #include "content/public/test/test_utils.h" | 18 #include "content/public/test/test_utils.h" |
| 19 #include "sync/api/attachments/attachment_id.h" | 19 #include "sync/api/attachments/attachment_id.h" |
| 20 #include "sync/api/fake_sync_change_processor.h" | 20 #include "sync/api/fake_sync_change_processor.h" |
| 21 #include "sync/api/sync_change.h" | 21 #include "sync/api/sync_change.h" |
| 22 #include "sync/api/sync_error_factory.h" | 22 #include "sync/api/sync_error_factory.h" |
| 23 #include "sync/api/sync_error_factory_mock.h" | 23 #include "sync/api/sync_error_factory_mock.h" |
| 24 #include "sync/api/syncable_service.h" | 24 #include "sync/api/syncable_service.h" |
| 25 #include "sync/internal_api/public/attachments/attachment_service_proxy_for_test
.h" | 25 #include "sync/internal_api/public/attachments/attachment_service_proxy_for_test
.h" |
| 26 #include "sync/protocol/sync.pb.h" | 26 #include "sync/protocol/sync.pb.h" |
| 27 | 27 |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 new base::FundamentalValue(true), | 215 new base::FundamentalValue(true), |
| 216 NULL); | 216 NULL); |
| 217 UpdateChromePolicy(policies); | 217 UpdateChromePolicy(policies); |
| 218 | 218 |
| 219 EXPECT_TRUE(prefs()->IsManagedPreference(prefs::kShowHomeButton)); | 219 EXPECT_TRUE(prefs()->IsManagedPreference(prefs::kShowHomeButton)); |
| 220 SetBooleanPrefValueFromSync(prefs::kShowHomeButton, false); | 220 SetBooleanPrefValueFromSync(prefs::kShowHomeButton, false); |
| 221 EXPECT_FALSE(observer.has_been_notified); | 221 EXPECT_FALSE(observer.has_been_notified); |
| 222 EXPECT_TRUE(GetBooleanPrefValue(prefs::kShowHomeButton)); | 222 EXPECT_TRUE(GetBooleanPrefValue(prefs::kShowHomeButton)); |
| 223 } | 223 } |
| 224 #endif | 224 #endif |
| OLD | NEW |