OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "net/spdy/spdy_proxy_client_socket.h" | 5 #include "net/spdy/spdy_proxy_client_socket.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "net/base/address_list.h" | 10 #include "net/base/address_list.h" |
11 #include "net/base/capturing_net_log.h" | 11 #include "net/base/capturing_net_log.h" |
12 #include "net/base/net_log.h" | 12 #include "net/base/net_log.h" |
13 #include "net/base/net_log_unittest.h" | 13 #include "net/base/net_log_unittest.h" |
14 #include "net/base/mock_host_resolver.h" | |
15 #include "net/base/test_completion_callback.h" | 14 #include "net/base/test_completion_callback.h" |
16 #include "net/base/winsock_init.h" | 15 #include "net/base/winsock_init.h" |
| 16 #include "net/dns/mock_host_resolver.h" |
| 17 #include "net/http/http_response_headers.h" |
17 #include "net/http/http_response_info.h" | 18 #include "net/http/http_response_info.h" |
18 #include "net/http/http_response_headers.h" | |
19 #include "net/socket/client_socket_factory.h" | 19 #include "net/socket/client_socket_factory.h" |
| 20 #include "net/socket/socket_test_util.h" |
20 #include "net/socket/tcp_client_socket.h" | 21 #include "net/socket/tcp_client_socket.h" |
21 #include "net/socket/socket_test_util.h" | |
22 #include "net/spdy/buffered_spdy_framer.h" | 22 #include "net/spdy/buffered_spdy_framer.h" |
23 #include "net/spdy/spdy_http_utils.h" | 23 #include "net/spdy/spdy_http_utils.h" |
24 #include "net/spdy/spdy_protocol.h" | 24 #include "net/spdy/spdy_protocol.h" |
25 #include "net/spdy/spdy_session_pool.h" | 25 #include "net/spdy/spdy_session_pool.h" |
26 #include "net/spdy/spdy_test_util_common.h" | 26 #include "net/spdy/spdy_test_util_common.h" |
27 #include "net/spdy/spdy_test_util_spdy2.h" | 27 #include "net/spdy/spdy_test_util_spdy2.h" |
| 28 #include "testing/gtest/include/gtest/gtest.h" |
28 #include "testing/platform_test.h" | 29 #include "testing/platform_test.h" |
29 #include "testing/gtest/include/gtest/gtest.h" | |
30 | 30 |
31 using namespace net::test_spdy2; | 31 using namespace net::test_spdy2; |
32 | 32 |
33 //----------------------------------------------------------------------------- | 33 //----------------------------------------------------------------------------- |
34 | 34 |
35 namespace { | 35 namespace { |
36 | 36 |
37 static const char kRequestUrl[] = "https://www.google.com/"; | 37 static const char kRequestUrl[] = "https://www.google.com/"; |
38 static const char kOriginHost[] = "www.google.com"; | 38 static const char kOriginHost[] = "www.google.com"; |
39 static const int kOriginPort = 443; | 39 static const int kOriginPort = 443; |
(...skipping 1367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1407 write_callback_.callback())); | 1407 write_callback_.callback())); |
1408 | 1408 |
1409 Run(2); | 1409 Run(2); |
1410 | 1410 |
1411 EXPECT_FALSE(sock_.get()); | 1411 EXPECT_FALSE(sock_.get()); |
1412 EXPECT_TRUE(read_callback.have_result()); | 1412 EXPECT_TRUE(read_callback.have_result()); |
1413 EXPECT_FALSE(write_callback_.have_result()); | 1413 EXPECT_FALSE(write_callback_.have_result()); |
1414 } | 1414 } |
1415 | 1415 |
1416 } // namespace net | 1416 } // namespace net |
OLD | NEW |