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

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

Issue 2363003: Rework the logging for sockets/connectjobs.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « net/spdy/spdy_network_transaction_unittest.cc ('k') | net/spdy/spdy_stream_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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_io_buffer.h" 5 #include "net/spdy/spdy_io_buffer.h"
6 6
7 #include "googleurl/src/gurl.h" 7 #include "googleurl/src/gurl.h"
8 #include "net/base/mock_host_resolver.h" 8 #include "net/base/mock_host_resolver.h"
9 #include "net/base/ssl_config_service_defaults.h" 9 #include "net/base/ssl_config_service_defaults.h"
10 #include "net/base/test_completion_callback.h" 10 #include "net/base/test_completion_callback.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 scoped_refptr<SpdySessionPool> spdy_session_pool; 48 scoped_refptr<SpdySessionPool> spdy_session_pool;
49 }; 49 };
50 50
51 HttpNetworkSession* CreateSession(SessionDependencies* session_deps) { 51 HttpNetworkSession* CreateSession(SessionDependencies* session_deps) {
52 return new HttpNetworkSession(NULL, 52 return new HttpNetworkSession(NULL,
53 session_deps->host_resolver, 53 session_deps->host_resolver,
54 session_deps->proxy_service, 54 session_deps->proxy_service,
55 &session_deps->socket_factory, 55 &session_deps->socket_factory,
56 session_deps->ssl_config_service, 56 session_deps->ssl_config_service,
57 session_deps->spdy_session_pool, 57 session_deps->spdy_session_pool,
58 NULL,
58 NULL); 59 NULL);
59 } 60 }
60 61
61 // Test the SpdyIOBuffer class. 62 // Test the SpdyIOBuffer class.
62 TEST_F(SpdySessionTest, SpdyIOBuffer) { 63 TEST_F(SpdySessionTest, SpdyIOBuffer) {
63 std::priority_queue<SpdyIOBuffer> queue_; 64 std::priority_queue<SpdyIOBuffer> queue_;
64 const size_t kQueueSize = 100; 65 const size_t kQueueSize = 100;
65 66
66 // Insert 100 items; pri 100 to 1. 67 // Insert 100 items; pri 100 to 1.
67 for (size_t index = 0; index < kQueueSize; ++index) { 68 for (size_t index = 0; index < kQueueSize; ++index) {
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 session = NULL; 240 session = NULL;
240 spdy_session_pool->CloseAllSessions(); 241 spdy_session_pool->CloseAllSessions();
241 242
242 // RunAllPending needs to be called here because the 243 // RunAllPending needs to be called here because the
243 // ClientSocketPoolBase posts a task to clean up and destroy the 244 // ClientSocketPoolBase posts a task to clean up and destroy the
244 // underlying socket. 245 // underlying socket.
245 MessageLoop::current()->RunAllPending(); 246 MessageLoop::current()->RunAllPending();
246 } 247 }
247 248
248 } // namespace net 249 } // namespace net
OLDNEW
« no previous file with comments | « net/spdy/spdy_network_transaction_unittest.cc ('k') | net/spdy/spdy_stream_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698