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_session.h" | 5 #include "net/spdy/spdy_session.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <memory> | 8 #include <memory> |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 ClientSocketPoolManager::set_max_sockets_per_pool( | 139 ClientSocketPoolManager::set_max_sockets_per_pool( |
140 HttpNetworkSession::NORMAL_SOCKET_POOL, old_max_pool_sockets_); | 140 HttpNetworkSession::NORMAL_SOCKET_POOL, old_max_pool_sockets_); |
141 ClientSocketPoolManager::set_max_sockets_per_group( | 141 ClientSocketPoolManager::set_max_sockets_per_group( |
142 HttpNetworkSession::NORMAL_SOCKET_POOL, old_max_group_sockets_); | 142 HttpNetworkSession::NORMAL_SOCKET_POOL, old_max_group_sockets_); |
143 } | 143 } |
144 | 144 |
145 void SetUp() override { | 145 void SetUp() override { |
146 g_time_delta = base::TimeDelta(); | 146 g_time_delta = base::TimeDelta(); |
147 g_time_now = base::TimeTicks::Now(); | 147 g_time_now = base::TimeTicks::Now(); |
148 session_deps_.net_log = log_.bound().net_log(); | 148 session_deps_.net_log = log_.bound().net_log(); |
149 session_deps_.enable_server_push_cancellation = true; | |
150 } | 149 } |
151 | 150 |
152 void CreateNetworkSession() { | 151 void CreateNetworkSession() { |
153 DCHECK(!http_session_); | 152 DCHECK(!http_session_); |
154 DCHECK(!spdy_session_pool_); | 153 DCHECK(!spdy_session_pool_); |
155 http_session_ = | 154 http_session_ = |
156 SpdySessionDependencies::SpdyCreateSession(&session_deps_); | 155 SpdySessionDependencies::SpdyCreateSession(&session_deps_); |
157 std::unique_ptr<TestServerPushDelegate> test_push_delegate( | 156 std::unique_ptr<TestServerPushDelegate> test_push_delegate( |
158 new TestServerPushDelegate()); | 157 new TestServerPushDelegate()); |
159 test_push_delegate_ = test_push_delegate.get(); | 158 test_push_delegate_ = test_push_delegate.get(); |
(...skipping 5841 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6001 ssl_info.cert = ImportCertFromFile(GetTestCertsDirectory(), | 6000 ssl_info.cert = ImportCertFromFile(GetTestCertsDirectory(), |
6002 "spdy_pooling.pem"); | 6001 "spdy_pooling.pem"); |
6003 ssl_info.is_issued_by_known_root = true; | 6002 ssl_info.is_issued_by_known_root = true; |
6004 ssl_info.public_key_hashes.push_back(test::GetTestHashValue(primary_pin)); | 6003 ssl_info.public_key_hashes.push_back(test::GetTestHashValue(primary_pin)); |
6005 | 6004 |
6006 EXPECT_TRUE(SpdySession::CanPool( | 6005 EXPECT_TRUE(SpdySession::CanPool( |
6007 &tss, ssl_info, "www.example.org", "mail.example.org")); | 6006 &tss, ssl_info, "www.example.org", "mail.example.org")); |
6008 } | 6007 } |
6009 | 6008 |
6010 } // namespace net | 6009 } // namespace net |
OLD | NEW |