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

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

Issue 1096203006: Collect all ConnectionAttempts from both sockets in TransportConnectJob. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@domrel_serverip1
Patch Set: Return fake ConnectionAttempt in MockTCPClientSocket Created 5 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
« no previous file with comments | « net/socket/ssl_client_socket_openssl.cc ('k') | net/socket/ssl_server_socket_nss.h » ('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) 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/socket/ssl_client_socket.h" 5 #include "net/socket/ssl_client_socket.h"
6 6
7 #include "base/callback_helpers.h" 7 #include "base/callback_helpers.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/thread_task_runner_handle.h" 10 #include "base/thread_task_runner_handle.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 } 101 }
102 bool WasNpnNegotiated() const override { 102 bool WasNpnNegotiated() const override {
103 return transport_->WasNpnNegotiated(); 103 return transport_->WasNpnNegotiated();
104 } 104 }
105 NextProto GetNegotiatedProtocol() const override { 105 NextProto GetNegotiatedProtocol() const override {
106 return transport_->GetNegotiatedProtocol(); 106 return transport_->GetNegotiatedProtocol();
107 } 107 }
108 bool GetSSLInfo(SSLInfo* ssl_info) override { 108 bool GetSSLInfo(SSLInfo* ssl_info) override {
109 return transport_->GetSSLInfo(ssl_info); 109 return transport_->GetSSLInfo(ssl_info);
110 } 110 }
111 void GetConnectionAttempts(ConnectionAttempts* out) const override {
112 transport_->GetConnectionAttempts(out);
113 }
114 void ClearConnectionAttempts() override {
115 transport_->ClearConnectionAttempts();
116 }
117 void AddConnectionAttempts(const ConnectionAttempts& attempts) override {
118 transport_->AddConnectionAttempts(attempts);
119 }
111 120
112 // Socket implementation: 121 // Socket implementation:
113 int Read(IOBuffer* buf, 122 int Read(IOBuffer* buf,
114 int buf_len, 123 int buf_len,
115 const CompletionCallback& callback) override { 124 const CompletionCallback& callback) override {
116 return transport_->Read(buf, buf_len, callback); 125 return transport_->Read(buf, buf_len, callback);
117 } 126 }
118 int Write(IOBuffer* buf, 127 int Write(IOBuffer* buf,
119 int buf_len, 128 int buf_len,
120 const CompletionCallback& callback) override { 129 const CompletionCallback& callback) override {
(...skipping 3312 matching lines...) Expand 10 before | Expand all | Expand 10 after
3433 ssl_config.channel_id_enabled = true; 3442 ssl_config.channel_id_enabled = true;
3434 3443
3435 int rv; 3444 int rv;
3436 ASSERT_TRUE(CreateAndConnectSSLClientSocket(ssl_config, &rv)); 3445 ASSERT_TRUE(CreateAndConnectSSLClientSocket(ssl_config, &rv));
3437 3446
3438 EXPECT_EQ(ERR_UNEXPECTED, rv); 3447 EXPECT_EQ(ERR_UNEXPECTED, rv);
3439 EXPECT_FALSE(sock_->IsConnected()); 3448 EXPECT_FALSE(sock_->IsConnected());
3440 } 3449 }
3441 3450
3442 } // namespace net 3451 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/ssl_client_socket_openssl.cc ('k') | net/socket/ssl_server_socket_nss.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698