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

Side by Side Diff: jingle/glue/fake_ssl_client_socket_unittest.cc

Issue 217573002: make SetReceiveBufferSize and SetSendBufferSize return net error codes (instead of bools) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: process error code in quic_stream_factory Created 6 years, 8 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
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 "jingle/glue/fake_ssl_client_socket.h" 5 #include "jingle/glue/fake_ssl_client_socket.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 // Used by PassThroughMethods test. 44 // Used by PassThroughMethods test.
45 class MockClientSocket : public net::StreamSocket { 45 class MockClientSocket : public net::StreamSocket {
46 public: 46 public:
47 virtual ~MockClientSocket() {} 47 virtual ~MockClientSocket() {}
48 48
49 MOCK_METHOD3(Read, int(net::IOBuffer*, int, 49 MOCK_METHOD3(Read, int(net::IOBuffer*, int,
50 const net::CompletionCallback&)); 50 const net::CompletionCallback&));
51 MOCK_METHOD3(Write, int(net::IOBuffer*, int, 51 MOCK_METHOD3(Write, int(net::IOBuffer*, int,
52 const net::CompletionCallback&)); 52 const net::CompletionCallback&));
53 MOCK_METHOD1(SetReceiveBufferSize, bool(int32)); 53 MOCK_METHOD1(SetReceiveBufferSize, int(int32));
54 MOCK_METHOD1(SetSendBufferSize, bool(int32)); 54 MOCK_METHOD1(SetSendBufferSize, int(int32));
55 MOCK_METHOD1(Connect, int(const net::CompletionCallback&)); 55 MOCK_METHOD1(Connect, int(const net::CompletionCallback&));
56 MOCK_METHOD0(Disconnect, void()); 56 MOCK_METHOD0(Disconnect, void());
57 MOCK_CONST_METHOD0(IsConnected, bool()); 57 MOCK_CONST_METHOD0(IsConnected, bool());
58 MOCK_CONST_METHOD0(IsConnectedAndIdle, bool()); 58 MOCK_CONST_METHOD0(IsConnectedAndIdle, bool());
59 MOCK_CONST_METHOD1(GetPeerAddress, int(net::IPEndPoint*)); 59 MOCK_CONST_METHOD1(GetPeerAddress, int(net::IPEndPoint*));
60 MOCK_CONST_METHOD1(GetLocalAddress, int(net::IPEndPoint*)); 60 MOCK_CONST_METHOD1(GetLocalAddress, int(net::IPEndPoint*));
61 MOCK_CONST_METHOD0(NetLog, const net::BoundNetLog&()); 61 MOCK_CONST_METHOD0(NetLog, const net::BoundNetLog&());
62 MOCK_METHOD0(SetSubresourceSpeculation, void()); 62 MOCK_METHOD0(SetSubresourceSpeculation, void());
63 MOCK_METHOD0(SetOmniboxSpeculation, void()); 63 MOCK_METHOD0(SetOmniboxSpeculation, void());
64 MOCK_CONST_METHOD0(WasEverUsed, bool()); 64 MOCK_CONST_METHOD0(WasEverUsed, bool());
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
340 } 340 }
341 341
342 TEST_F(FakeSSLClientSocketTest, MalformedServerHello) { 342 TEST_F(FakeSSLClientSocketTest, MalformedServerHello) {
343 RunUnsuccessfulHandshakeTest(ERR_MALFORMED_SERVER_HELLO, 343 RunUnsuccessfulHandshakeTest(ERR_MALFORMED_SERVER_HELLO,
344 VERIFY_SERVER_HELLO_ERROR); 344 VERIFY_SERVER_HELLO_ERROR);
345 } 345 }
346 346
347 } // namespace 347 } // namespace
348 348
349 } // namespace jingle_glue 349 } // namespace jingle_glue
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698