Index: net/spdy/spdy_session_unittest.cc |
diff --git a/net/spdy/spdy_session_unittest.cc b/net/spdy/spdy_session_unittest.cc |
index 10901fa54e1ea247c3c4654e90c7061f23e34ee2..bf9a5f33d1204561940ba5f7151ed55f1fd915bc 100644 |
--- a/net/spdy/spdy_session_unittest.cc |
+++ b/net/spdy/spdy_session_unittest.cc |
@@ -12,14 +12,17 @@ |
#include "base/memory/scoped_ptr.h" |
#include "base/run_loop.h" |
#include "base/test/histogram_tester.h" |
+#include "net/base/host_port_pair.h" |
#include "net/base/io_buffer.h" |
#include "net/base/ip_endpoint.h" |
+#include "net/base/proxy_delegate.h" |
#include "net/base/request_priority.h" |
#include "net/base/test_data_directory.h" |
#include "net/base/test_data_stream.h" |
#include "net/log/test_net_log.h" |
#include "net/log/test_net_log_entry.h" |
#include "net/log/test_net_log_util.h" |
+#include "net/proxy/proxy_server.h" |
#include "net/socket/client_socket_pool_manager.h" |
#include "net/socket/next_proto.h" |
#include "net/socket/socket_test_util.h" |
@@ -4931,6 +4934,11 @@ TEST_P(SpdySessionTest, TrustedSpdyProxy) { |
ASSERT_NE(GURL(kDefaultURL).host(), GURL(kHttpURLFromAnotherOrigin).host()); |
ASSERT_NE(GURL(kDefaultURL).host(), GURL(kHttpsURLFromAnotherOrigin).host()); |
+ scoped_ptr<TestProxyDelegate> proxy_delegate(new TestProxyDelegate()); |
Bence
2016/02/03 00:40:04
Move these new lines down to just above line 4968
tbansal1
2016/02/03 01:22:49
Done.
|
+ proxy_delegate->set_trusted_spdy_proxy( |
+ net::ProxyServer(net::ProxyServer::SCHEME_HTTPS, |
+ HostPortPair(GURL(kDefaultURL).host(), 80))); |
+ |
// cross_origin_push contains HTTP resource for an origin different from the |
// origin of kDefaultURL, and should be accepted. |
scoped_ptr<SpdyFrame> cross_origin_push(spdy_util_.ConstructSpdyPush( |
@@ -4957,8 +4965,7 @@ TEST_P(SpdySessionTest, TrustedSpdyProxy) { |
SequencedSocketData data(reads, arraysize(reads), writes, arraysize(writes)); |
session_deps_.socket_factory->AddSocketDataProvider(&data); |
- session_deps_.trusted_spdy_proxy = |
- HostPortPair::FromURL(GURL(kDefaultURL)).ToString(); |
+ session_deps_.proxy_delegate.reset(proxy_delegate.release()); |
CreateNetworkSession(); |
CreateInsecureSpdySession(); |