Index: chrome/browser/chromeos/gview_request_interceptor_unittest.cc |
=================================================================== |
--- chrome/browser/chromeos/gview_request_interceptor_unittest.cc (revision 154991) |
+++ chrome/browser/chromeos/gview_request_interceptor_unittest.cc (working copy) |
@@ -13,6 +13,7 @@ |
#include "chrome/browser/plugin_prefs_factory.h" |
#include "chrome/common/chrome_paths.h" |
#include "chrome/test/base/testing_pref_service.h" |
+#include "chrome/test/base/testing_profile.h" |
#include "content/public/browser/plugin_service.h" |
#include "content/public/browser/resource_request_info.h" |
#include "content/public/test/mock_resource_context.h" |
@@ -102,9 +103,8 @@ |
job_factory_.SetProtocolHandler("http", new GViewRequestProtocolFactory); |
job_factory_.AddInterceptor(new GViewRequestInterceptor); |
request_context->set_job_factory(&job_factory_); |
- PluginPrefsFactory::GetInstance()->ForceRegisterPrefsForTest(&prefs_); |
- plugin_prefs_ = new PluginPrefs(); |
- plugin_prefs_->SetPrefs(&prefs_); |
+ plugin_prefs_ = PluginPrefs::GetForTestingProfile(&profile_); |
+ PluginPrefsFactory::GetInstance()->RegisterUserPrefsOnProfile(&profile_); |
ChromePluginServiceFilter* filter = |
ChromePluginServiceFilter::GetInstance(); |
filter->RegisterResourceContext(plugin_prefs_, &resource_context_); |
@@ -174,7 +174,7 @@ |
content::TestBrowserThread file_thread_; |
content::TestBrowserThread io_thread_; |
webkit::npapi::MockPluginList plugin_list_; |
- TestingPrefService prefs_; |
+ TestingProfile profile_; |
scoped_refptr<PluginPrefs> plugin_prefs_; |
net::URLRequestJobFactoryImpl job_factory_; |
const net::URLRequestJobFactory* old_factory_; |