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

Unified Diff: content/browser/android/url_request_content_job_unittest.cc

Issue 2130493002: Implement THROTTLED priority semantics. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@NetworkStreamThrottler
Patch Set: Fix use of message_loop_ in Android tests. Created 4 years, 1 month 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 | « components/cronet/url_request_context_config_unittest.cc ('k') | net/base/network_throttle_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/android/url_request_content_job_unittest.cc
diff --git a/content/browser/android/url_request_content_job_unittest.cc b/content/browser/android/url_request_content_job_unittest.cc
index c87f7e151267c03ef832e7c03bbdfab8d83e3520..1d1c58a60d63abeda5c0796d48a358c3c5a91947 100644
--- a/content/browser/android/url_request_content_job_unittest.cc
+++ b/content/browser/android/url_request_content_job_unittest.cc
@@ -13,11 +13,11 @@
#include "base/run_loop.h"
#include "base/strings/stringprintf.h"
#include "base/test/test_file_util.h"
+#include "base/threading/thread_task_runner_handle.h"
#include "net/url_request/url_request.h"
#include "net/url_request/url_request_test_util.h"
#include "testing/gtest/include/gtest/gtest.h"
-
namespace content {
namespace {
@@ -47,7 +47,7 @@ class CallbacksJobFactory : public net::URLRequestJobFactory {
request,
network_delegate,
path_,
- const_cast<base::MessageLoop*>(&message_loop_)->task_runner());
+ base::ThreadTaskRunnerHandle::Get());
observer_->OnJobCreated();
return job;
}
@@ -78,7 +78,6 @@ class CallbacksJobFactory : public net::URLRequestJobFactory {
}
private:
- base::MessageLoop message_loop_;
base::FilePath path_;
JobObserver* observer_;
};
@@ -121,6 +120,7 @@ class URLRequestContentJobTest : public testing::Test {
// retrieved.
void RunRequest(const Range* range);
+ base::MessageLoop message_loop_;
JobObserverImpl observer_;
net::TestURLRequestContext context_;
net::TestDelegate delegate_;
« no previous file with comments | « components/cronet/url_request_context_config_unittest.cc ('k') | net/base/network_throttle_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698