diff options
author | mmenke@chromium.org <mmenke@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-03 01:51:27 +0000 |
---|---|---|
committer | mmenke@chromium.org <mmenke@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-03 01:51:27 +0000 |
commit | ef41e3e9650952ff791f558d1292e004d04598f4 (patch) | |
tree | ad1ae6da8ca7abe772073106eb3734d2981bd7a7 /chrome | |
parent | 6ba3674fce6a1837f6fce6134db3364a9d8d8d51 (diff) | |
download | chromium_src-ef41e3e9650952ff791f558d1292e004d04598f4.zip chromium_src-ef41e3e9650952ff791f558d1292e004d04598f4.tar.gz chromium_src-ef41e3e9650952ff791f558d1292e004d04598f4.tar.bz2 |
Increase prerender memory limit on NetInternalsTests,
preventing prerendering from being killed for exceeding it.
TEST=NetInternalsTest.NetInternalsPrerenderView*
BUG=none
Review URL: http://codereview.chromium.org/7835002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@99503 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/ui/webui/net_internals_ui_browsertest.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/chrome/browser/ui/webui/net_internals_ui_browsertest.cc b/chrome/browser/ui/webui/net_internals_ui_browsertest.cc index 6b6ead9..c9b5aba 100644 --- a/chrome/browser/ui/webui/net_internals_ui_browsertest.cc +++ b/chrome/browser/ui/webui/net_internals_ui_browsertest.cc @@ -6,11 +6,15 @@ #include "base/file_path.h" #include "base/utf_string_conversions.h" #include "chrome/browser/prerender/prerender_final_status.h" +#include "chrome/browser/prerender/prerender_manager.h" +#include "chrome/browser/profiles/profile.h" #include "chrome/browser/ui/browser.h" +#include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" #include "chrome/browser/ui/webui/web_ui_browsertest.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/url_constants.h" #include "chrome/test/base/ui_test_utils.h" +#include "content/browser/tab_contents/tab_contents.h" #include "googleurl/src/gurl.h" #include "net/base/net_errors.h" #include "testing/gtest/include/gtest/gtest.h" @@ -112,6 +116,12 @@ void NetInternalsTest::SetUpOnMainThread() { // Navigate to chrome://net-internals. ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUINetInternalsURL)); + // Increase the memory allowed in a prerendered page above normal settings, + // as debug builds use more memory and often go over the usual limit. + Profile* profile = browser()->GetSelectedTabContentsWrapper()->profile(); + prerender::PrerenderManager* prerender_manager = + profile->GetPrerenderManager(); + prerender_manager->mutable_config().max_bytes = 1000 * 1024 * 1024; } //////////////////////////////////////////////////////////////////////////////// |