summaryrefslogtreecommitdiffstats
path: root/content/test/test_browser_context.cc
diff options
context:
space:
mode:
authorphajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-02 21:39:03 +0000
committerphajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-02 21:39:03 +0000
commit826ad711429cb169c4772ffa210d1ef2c952ee43 (patch)
tree4c384324c9d033021868cd65991b8dc4d08db485 /content/test/test_browser_context.cc
parentcd0cc3b26c9bb9c65e25895135296bfcc6c8d397 (diff)
downloadchromium_src-826ad711429cb169c4772ffa210d1ef2c952ee43.zip
chromium_src-826ad711429cb169c4772ffa210d1ef2c952ee43.tar.gz
chromium_src-826ad711429cb169c4772ffa210d1ef2c952ee43.tar.bz2
Move more files to content_unittests
and a few related cleanups: - DCHECK in ctor to fail early - fix infinite loop in WebUI mock - ASSERT_TRUE to avoid crashes BUG=90443 Review URL: http://codereview.chromium.org/7830028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@99459 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/test/test_browser_context.cc')
-rw-r--r--content/test/test_browser_context.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/content/test/test_browser_context.cc b/content/test/test_browser_context.cc
index 728b98f..42388b8 100644
--- a/content/test/test_browser_context.cc
+++ b/content/test/test_browser_context.cc
@@ -5,6 +5,7 @@
#include "content/test/test_browser_context.h"
#include "base/file_path.h"
+#include "content/browser/in_process_webkit/webkit_context.h"
#include "content/browser/mock_resource_context.h"
TestBrowserContext::TestBrowserContext() {
@@ -73,7 +74,12 @@ bool TestBrowserContext::DidLastSessionExitCleanly() {
}
WebKitContext* TestBrowserContext::GetWebKitContext() {
- return NULL;
+ if (webkit_context_ == NULL) {
+ webkit_context_ = new WebKitContext(
+ IsOffTheRecord(), GetPath(),
+ NULL, false, NULL, NULL);
+ }
+ return webkit_context_;
}
ChromeBlobStorageContext* TestBrowserContext::GetBlobStorageContext() {