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

Side by Side Diff: net/socket/ssl_test_util.cc

Issue 1783008: Cleanup: Remove the implicit constructor for BoundNetLog that allowed passing... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Sync Created 10 years, 7 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/socket/ssl_client_socket_unittest.cc ('k') | net/socket/tcp_client_socket_pool_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/socket/ssl_test_util.h" 5 #include "net/socket/ssl_test_util.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 return true; 215 return true;
216 } 216 }
217 217
218 bool TestServerLauncher::WaitToStart(const std::string& host_name, int port) { 218 bool TestServerLauncher::WaitToStart(const std::string& host_name, int port) {
219 // Verify that the webserver is actually started. 219 // Verify that the webserver is actually started.
220 // Otherwise tests can fail if they run faster than Python can start. 220 // Otherwise tests can fail if they run faster than Python can start.
221 net::AddressList addr; 221 net::AddressList addr;
222 scoped_refptr<net::HostResolver> resolver( 222 scoped_refptr<net::HostResolver> resolver(
223 net::CreateSystemHostResolver(NULL)); 223 net::CreateSystemHostResolver(NULL));
224 net::HostResolver::RequestInfo info(host_name, port); 224 net::HostResolver::RequestInfo info(host_name, port);
225 int rv = resolver->Resolve(info, &addr, NULL, NULL, NULL); 225 int rv = resolver->Resolve(info, &addr, NULL, NULL, BoundNetLog());
226 if (rv != net::OK) 226 if (rv != net::OK)
227 return false; 227 return false;
228 228
229 net::TCPPinger pinger(addr); 229 net::TCPPinger pinger(addr);
230 rv = pinger.Ping(base::TimeDelta::FromMilliseconds(connection_timeout_), 230 rv = pinger.Ping(base::TimeDelta::FromMilliseconds(connection_timeout_),
231 connection_attempts_); 231 connection_attempts_);
232 return rv == net::OK; 232 return rv == net::OK;
233 } 233 }
234 234
235 bool TestServerLauncher::WaitToFinish(int timeout_ms) { 235 bool TestServerLauncher::WaitToFinish(int timeout_ms) {
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
340 "certificate to your trusted roots for this test to work. " 340 "certificate to your trusted roots for this test to work. "
341 "For more info visit:\n" 341 "For more info visit:\n"
342 "http://dev.chromium.org/developers/testing\n"; 342 "http://dev.chromium.org/developers/testing\n";
343 return false; 343 return false;
344 } 344 }
345 #endif 345 #endif
346 return true; 346 return true;
347 } 347 }
348 348
349 } // namespace net 349 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/ssl_client_socket_unittest.cc ('k') | net/socket/tcp_client_socket_pool_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698