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

Unified Diff: net/url_request/url_request_context_builder_unittest.cc

Issue 22795006: Remove WorkerPool dependency from URLRequestFileJob. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix android include Created 7 years, 4 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: net/url_request/url_request_context_builder_unittest.cc
diff --git a/net/url_request/url_request_context_builder_unittest.cc b/net/url_request/url_request_context_builder_unittest.cc
index f747b4de7050fb3138fa90b104c11e6831fb7255..c80435ff69771f7d5041620943b71e3d1be7a35d 100644
--- a/net/url_request/url_request_context_builder_unittest.cc
+++ b/net/url_request/url_request_context_builder_unittest.cc
@@ -4,6 +4,7 @@
#include "net/url_request/url_request_context_builder.h"
+#include "base/run_loop.h"
#include "build/build_config.h"
#include "net/test/spawned_test_server/spawned_test_server.h"
#include "net/url_request/url_request.h"
@@ -39,7 +40,8 @@ class URLRequestContextBuilderTest : public PlatformTest {
protected:
URLRequestContextBuilderTest()
: test_server_(
- base::FilePath(FILE_PATH_LITERAL("net/data/url_request_unittest"))) {
+ base::FilePath(FILE_PATH_LITERAL("net/data/url_request_unittest"))),
+ builder_(base::MessageLoopProxy::current()) {
#if defined(OS_LINUX) || defined(OS_ANDROID)
builder_.set_proxy_config_service(
new ProxyConfigServiceFixed(ProxyConfig::CreateDirect()));
@@ -60,7 +62,7 @@ TEST_F(URLRequestContextBuilderTest, DefaultSettings) {
request.set_method("GET");
request.SetExtraRequestHeaderByName("Foo", "Bar", false);
request.Start();
- base::MessageLoop::current()->Run();
+ base::RunLoop().Run();
EXPECT_EQ("Bar", delegate.data_received());
}
@@ -74,7 +76,7 @@ TEST_F(URLRequestContextBuilderTest, UserAgent) {
test_server_.GetURL("echoheader?User-Agent"), &delegate, context.get());
request.set_method("GET");
request.Start();
- base::MessageLoop::current()->Run();
+ base::RunLoop().Run();
EXPECT_EQ("Bar", delegate.data_received());
}

Powered by Google App Engine
This is Rietveld 408576698