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

Unified Diff: chrome/browser/prerender/prerender_browsertest.cc

Issue 2835233002: Fix integration tests in src/chrome and src/extensions so that we can turn on IO thread checks wi... (Closed)
Patch Set: ready for review Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/prefs/pref_service_browsertest.cc ('k') | chrome/browser/profiles/profile_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/prerender/prerender_browsertest.cc
diff --git a/chrome/browser/prerender/prerender_browsertest.cc b/chrome/browser/prerender/prerender_browsertest.cc
index 0c13cbc89e06597733d9145c23aeb97f0728ee48..10eae82a26ec94fbd84fd947d3d91f3414df25a5 100644
--- a/chrome/browser/prerender/prerender_browsertest.cc
+++ b/chrome/browser/prerender/prerender_browsertest.cc
@@ -27,6 +27,7 @@
#include "base/test/scoped_feature_list.h"
#include "base/test/simple_test_tick_clock.h"
#include "base/test/test_timeouts.h"
+#include "base/threading/thread_restrictions.h"
#include "base/values.h"
#include "build/build_config.h"
#include "chrome/browser/browsing_data/browsing_data_helper.h"
@@ -3260,10 +3261,13 @@ IN_PROC_BROWSER_TEST_F(PrerenderBrowserTest, HttpPost) {
// Manager API. The page should be killed.
IN_PROC_BROWSER_TEST_F(PrerenderBrowserTest, AutosigninInPrerenderer) {
// Set up a credential in the password store.
- PasswordStoreFactory::GetInstance()->SetTestingFactory(
- current_browser()->profile(),
- password_manager::BuildPasswordStore<
- content::BrowserContext, password_manager::TestPasswordStore>);
+ {
+ base::ThreadRestrictions::ScopedAllowIO allow_io;
+ PasswordStoreFactory::GetInstance()->SetTestingFactory(
+ current_browser()->profile(),
+ password_manager::BuildPasswordStore<
+ content::BrowserContext, password_manager::TestPasswordStore>);
+ }
scoped_refptr<password_manager::TestPasswordStore> password_store =
static_cast<password_manager::TestPasswordStore*>(
PasswordStoreFactory::GetForProfile(
« no previous file with comments | « chrome/browser/prefs/pref_service_browsertest.cc ('k') | chrome/browser/profiles/profile_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698