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

Side by Side Diff: net/spdy/spdy_session_unittest.cc

Issue 1298253002: Remove reference counting from HttpNetworkSession. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed too much, back up a bit Created 5 years, 3 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 unified diff | Download patch
OLDNEW
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 "base/base64.h" 7 #include "base/base64.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 const base::Callback<void(SpdyStream*)>& stall_function, 160 const base::Callback<void(SpdyStream*)>& stall_function,
161 const base::Callback<void(SpdyStream*, int32)>& unstall_function); 161 const base::Callback<void(SpdyStream*, int32)>& unstall_function);
162 162
163 // Original socket limits. Some tests set these. Safest to always restore 163 // Original socket limits. Some tests set these. Safest to always restore
164 // them once each test has been run. 164 // them once each test has been run.
165 int old_max_group_sockets_; 165 int old_max_group_sockets_;
166 int old_max_pool_sockets_; 166 int old_max_pool_sockets_;
167 167
168 SpdyTestUtil spdy_util_; 168 SpdyTestUtil spdy_util_;
169 SpdySessionDependencies session_deps_; 169 SpdySessionDependencies session_deps_;
170 scoped_refptr<HttpNetworkSession> http_session_; 170 scoped_ptr<HttpNetworkSession> http_session_;
171 base::WeakPtr<SpdySession> session_; 171 base::WeakPtr<SpdySession> session_;
172 SpdySessionPool* spdy_session_pool_; 172 SpdySessionPool* spdy_session_pool_;
173 GURL test_url_; 173 GURL test_url_;
174 HostPortPair test_host_port_pair_; 174 HostPortPair test_host_port_pair_;
175 SpdySessionKey key_; 175 SpdySessionKey key_;
176 BoundTestNetLog log_; 176 BoundTestNetLog log_;
177 }; 177 };
178 178
179 INSTANTIATE_TEST_CASE_P(NextProto, 179 INSTANTIATE_TEST_CASE_P(NextProto,
180 SpdySessionTest, 180 SpdySessionTest,
(...skipping 4858 matching lines...) Expand 10 before | Expand all | Expand 10 after
5039 ssl_info.cert = ImportCertFromFile(GetTestCertsDirectory(), 5039 ssl_info.cert = ImportCertFromFile(GetTestCertsDirectory(),
5040 "spdy_pooling.pem"); 5040 "spdy_pooling.pem");
5041 ssl_info.is_issued_by_known_root = true; 5041 ssl_info.is_issued_by_known_root = true;
5042 ssl_info.public_key_hashes.push_back(test::GetTestHashValue(primary_pin)); 5042 ssl_info.public_key_hashes.push_back(test::GetTestHashValue(primary_pin));
5043 5043
5044 EXPECT_TRUE(SpdySession::CanPool( 5044 EXPECT_TRUE(SpdySession::CanPool(
5045 &tss, ssl_info, "www.example.org", "mail.example.org")); 5045 &tss, ssl_info, "www.example.org", "mail.example.org"));
5046 } 5046 }
5047 5047
5048 } // namespace net 5048 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698