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

Unified Diff: components/dom_distiller/standalone/content_extractor_browsertest.cc

Issue 2881853002: Use TaskScheduler instead of SequencedWorkerPool in content_extractor_browsertest.cc. (Closed)
Patch Set: Created 3 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/dom_distiller/standalone/content_extractor_browsertest.cc
diff --git a/components/dom_distiller/standalone/content_extractor_browsertest.cc b/components/dom_distiller/standalone/content_extractor_browsertest.cc
index 9047ce71b03b2c8e059b1e014ab3cdc1601aef2e..86aae713a8b861eab689afb5aac8b1358a63a905 100644
--- a/components/dom_distiller/standalone/content_extractor_browsertest.cc
+++ b/components/dom_distiller/standalone/content_extractor_browsertest.cc
@@ -16,6 +16,7 @@
#include "base/single_thread_task_runner.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/string_split.h"
+#include "base/task_scheduler/post_task.h"
#include "base/threading/thread_task_runner_handle.h"
#include "components/dom_distiller/content/browser/distiller_javascript_utils.h"
#include "components/dom_distiller/content/browser/distiller_page_web_contents.h"
@@ -31,7 +32,6 @@
#include "components/leveldb_proto/proto_database_impl.h"
#include "components/sync_preferences/testing_pref_service_syncable.h"
#include "content/public/browser/browser_context.h"
-#include "content/public/browser/browser_thread.h"
#include "content/public/browser/storage_partition.h"
#include "content/public/common/isolated_world_ids.h"
#include "content/public/test/content_browser_test.h"
@@ -126,10 +126,8 @@ std::unique_ptr<DomDistillerService> CreateDomDistillerService(
content::BrowserContext* context,
const base::FilePath& db_path,
const FileToUrlMap& file_to_url_map) {
- base::SequencedWorkerPool* blocking_pool =
- content::BrowserThread::GetBlockingPool();
scoped_refptr<base::SequencedTaskRunner> background_task_runner =
- blocking_pool->GetSequencedTaskRunner(blocking_pool->GetSequenceToken());
+ base::CreateSequencedTaskRunnerWithTraits({base::MayBlock()});
// TODO(cjhopman): use an in-memory database instead of an on-disk one with
// temporary directory.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698