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

Side by Side Diff: chrome/browser/content_settings/host_content_settings_map_unittest.cc

Issue 1658793002: Update chrome for new prefs location. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/auto_reset.h" 5 #include "base/auto_reset.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/json/json_reader.h" 7 #include "base/json/json_reader.h"
8 #include "base/json/json_writer.h" 8 #include "base/json/json_writer.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/prefs/pref_service.h"
11 #include "base/prefs/scoped_user_pref_update.h"
12 #include "chrome/browser/content_settings/content_settings_mock_observer.h" 10 #include "chrome/browser/content_settings/content_settings_mock_observer.h"
13 #include "chrome/browser/content_settings/cookie_settings_factory.h" 11 #include "chrome/browser/content_settings/cookie_settings_factory.h"
14 #include "chrome/browser/content_settings/host_content_settings_map_factory.h" 12 #include "chrome/browser/content_settings/host_content_settings_map_factory.h"
15 #include "chrome/browser/content_settings/mock_settings_observer.h" 13 #include "chrome/browser/content_settings/mock_settings_observer.h"
16 #include "chrome/common/url_constants.h" 14 #include "chrome/common/url_constants.h"
17 #include "chrome/test/base/testing_profile.h" 15 #include "chrome/test/base/testing_profile.h"
18 #include "components/content_settings/core/browser/content_settings_details.h" 16 #include "components/content_settings/core/browser/content_settings_details.h"
19 #include "components/content_settings/core/browser/cookie_settings.h" 17 #include "components/content_settings/core/browser/cookie_settings.h"
20 #include "components/content_settings/core/browser/host_content_settings_map.h" 18 #include "components/content_settings/core/browser/host_content_settings_map.h"
21 #include "components/content_settings/core/browser/website_settings_info.h" 19 #include "components/content_settings/core/browser/website_settings_info.h"
22 #include "components/content_settings/core/browser/website_settings_registry.h" 20 #include "components/content_settings/core/browser/website_settings_registry.h"
23 #include "components/content_settings/core/common/pref_names.h" 21 #include "components/content_settings/core/common/pref_names.h"
22 #include "components/prefs/pref_service.h"
23 #include "components/prefs/scoped_user_pref_update.h"
24 #include "components/syncable_prefs/testing_pref_service_syncable.h" 24 #include "components/syncable_prefs/testing_pref_service_syncable.h"
25 #include "content/public/test/test_browser_thread.h" 25 #include "content/public/test/test_browser_thread.h"
26 #include "net/base/static_cookie_policy.h" 26 #include "net/base/static_cookie_policy.h"
27 #include "testing/gtest/include/gtest/gtest.h" 27 #include "testing/gtest/include/gtest/gtest.h"
28 #include "url/gurl.h" 28 #include "url/gurl.h"
29 29
30 using content::BrowserThread; 30 using content::BrowserThread;
31 31
32 using ::testing::_; 32 using ::testing::_;
33 33
(...skipping 1193 matching lines...) Expand 10 before | Expand all | Expand 10 after
1227 profile.GetPrefs()->Set(GetPrefName(CONTENT_SETTINGS_TYPE_IMAGES), *value); 1227 profile.GetPrefs()->Set(GetPrefName(CONTENT_SETTINGS_TYPE_IMAGES), *value);
1228 1228
1229 // Test that during construction all the prefs get cleared. 1229 // Test that during construction all the prefs get cleared.
1230 HostContentSettingsMapFactory::GetForProfile(&profile); 1230 HostContentSettingsMapFactory::GetForProfile(&profile);
1231 1231
1232 const base::DictionaryValue* all_settings_dictionary = 1232 const base::DictionaryValue* all_settings_dictionary =
1233 profile.GetPrefs()->GetDictionary( 1233 profile.GetPrefs()->GetDictionary(
1234 GetPrefName(CONTENT_SETTINGS_TYPE_IMAGES)); 1234 GetPrefName(CONTENT_SETTINGS_TYPE_IMAGES));
1235 EXPECT_TRUE(all_settings_dictionary->empty()); 1235 EXPECT_TRUE(all_settings_dictionary->empty());
1236 } 1236 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698