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

Unified Diff: chrome/browser/policy/policy_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
Index: chrome/browser/policy/policy_browsertest.cc
diff --git a/chrome/browser/policy/policy_browsertest.cc b/chrome/browser/policy/policy_browsertest.cc
index 021efe750aaa4860ad5a2228fd36f4e487290c9e..8fe1a46eb5a9123621cf7a4c969ec5965d034a3a 100644
--- a/chrome/browser/policy/policy_browsertest.cc
+++ b/chrome/browser/policy/policy_browsertest.cc
@@ -34,6 +34,7 @@
#include "base/test/scoped_feature_list.h"
#include "base/test/test_file_util.h"
#include "base/threading/sequenced_worker_pool.h"
+#include "base/threading/thread_restrictions.h"
#include "base/time/time.h"
#include "base/values.h"
#include "build/build_config.h"
@@ -875,6 +876,7 @@ IN_PROC_BROWSER_TEST_F(LocalePolicyTest, ApplicationLocaleValue) {
EXPECT_EQ(french_title, title);
// Make sure this is really French and differs from the English title.
+ base::ThreadRestrictions::ScopedAllowIO allow_io;
std::string loaded =
ui::ResourceBundle::GetSharedInstance().ReloadLocaleResources("en-US");
EXPECT_EQ("en-US", loaded);
@@ -1434,6 +1436,7 @@ IN_PROC_BROWSER_TEST_F(PolicyTest, DownloadDirectory) {
// Verifies that the download directory can be forced by policy.
// Set the initial download directory.
+ base::ThreadRestrictions::ScopedAllowIO allow_io;
base::ScopedTempDir initial_dir;
ASSERT_TRUE(initial_dir.CreateUniqueTempDir());
browser()->profile()->GetPrefs()->SetFilePath(
@@ -1832,6 +1835,7 @@ IN_PROC_BROWSER_TEST_F(PolicyTest, MAYBE_ExtensionInstallSources) {
URLRequestMockHTTPJob::GetMockUrl("extensions/*"));
const GURL referrer_url(URLRequestMockHTTPJob::GetMockUrl("policy/*"));
+ base::ThreadRestrictions::ScopedAllowIO allow_io;
base::ScopedTempDir download_directory;
ASSERT_TRUE(download_directory.CreateUniqueTempDir());
DownloadPrefs* download_prefs =
« no previous file with comments | « chrome/browser/policy/cloud/component_cloud_policy_browsertest.cc ('k') | chrome/browser/policy/policy_prefs_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698