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

Unified Diff: net/spdy/spdy_test_util.cc

Issue 6402002: Simplify HttpCache/HttpNetworkLayer/HttpNetworkSession interaction. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix nits. Created 9 years, 11 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 | « net/proxy/proxy_script_fetcher_impl_unittest.cc ('k') | net/tools/fetch/fetch_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_test_util.cc
diff --git a/net/spdy/spdy_test_util.cc b/net/spdy/spdy_test_util.cc
index 07a59807dc766aba0bbe97e8438799bed9d0fe2a..e7bde0a1e0f689437f8a634bba30e506a235e487 100644
--- a/net/spdy/spdy_test_util.cc
+++ b/net/spdy/spdy_test_util.cc
@@ -9,6 +9,7 @@
#include "base/basictypes.h"
#include "base/string_number_conversions.h"
#include "base/string_util.h"
+#include "net/http/http_network_session.h"
#include "net/http/http_network_transaction.h"
#include "net/spdy/spdy_framer.h"
@@ -924,20 +925,22 @@ SpdyURLRequestContext::SpdyURLRequestContext() {
ssl_config_service_ = new SSLConfigServiceDefaults;
http_auth_handler_factory_ = HttpAuthHandlerFactory::CreateDefault(
host_resolver_);
+ scoped_refptr<HttpNetworkSession> network_session(
+ new HttpNetworkSession(
+ host_resolver_,
+ cert_verifier_,
+ NULL /* dnsrr_resolver */,
+ NULL /* dns_cert_checker */,
+ NULL /* ssl_host_info_factory */,
+ proxy_service_,
+ &socket_factory_,
+ ssl_config_service_,
+ new SpdySessionPool(NULL),
+ http_auth_handler_factory_,
+ network_delegate_,
+ NULL /* net_log */));
http_transaction_factory_ = new HttpCache(
- new HttpNetworkLayer(&socket_factory_,
- host_resolver_,
- cert_verifier_,
- NULL /* dnsrr_resolver */,
- NULL /* dns_cert_checker */,
- NULL /* ssl_host_info_factory */,
- proxy_service_,
- ssl_config_service_,
- new SpdySessionPool(NULL),
- http_auth_handler_factory_,
- network_delegate_,
- NULL),
- NULL /* net_log */,
+ network_session,
HttpCache::DefaultBackend::InMemory(0));
}
« no previous file with comments | « net/proxy/proxy_script_fetcher_impl_unittest.cc ('k') | net/tools/fetch/fetch_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698