summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/test')
-rw-r--r--chrome/test/base/testing_profile.cc4
-rw-r--r--chrome/test/base/testing_profile.h3
2 files changed, 6 insertions, 1 deletions
diff --git a/chrome/test/base/testing_profile.cc b/chrome/test/base/testing_profile.cc
index 30f6b39..d2821e7 100644
--- a/chrome/test/base/testing_profile.cc
+++ b/chrome/test/base/testing_profile.cc
@@ -628,7 +628,9 @@ net::URLRequestContextGetter* TestingProfile::GetRequestContextForIsolatedApp(
}
content::ResourceContext* TestingProfile::GetResourceContext() {
- return content::MockResourceContext::GetInstance();
+ if (!resource_context_.get())
+ resource_context_.reset(new content::MockResourceContext());
+ return resource_context_.get();
}
HostContentSettingsMap* TestingProfile::GetHostContentSettingsMap() {
diff --git a/chrome/test/base/testing_profile.h b/chrome/test/base/testing_profile.h
index d39f3a2..f4db9ab 100644
--- a/chrome/test/base/testing_profile.h
+++ b/chrome/test/base/testing_profile.h
@@ -16,6 +16,7 @@
#include "content/browser/appcache/chrome_appcache_service.h"
namespace content {
+class MockResourceContext;
class SpeechInputPreferences;
}
@@ -384,6 +385,8 @@ class TestingProfile : public Profile {
// testing.
ProfileDependencyManager* profile_dependency_manager_;
+ scoped_ptr<content::MockResourceContext> resource_context_;
+
// Weak pointer to a delegate for indicating that a profile was created.
Delegate* delegate_;
};