| OLD | NEW |
| 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 // Common utilities for Quic tests | 5 // Common utilities for Quic tests |
| 6 | 6 |
| 7 #ifndef NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ | 7 #ifndef NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ |
| 8 #define NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ | 8 #define NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ |
| 9 | 9 |
| 10 #include <cstdint> | 10 #include <cstdint> |
| (...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 MOCK_METHOD1(OnCongestionWindowChange, void(QuicTime now)); | 303 MOCK_METHOD1(OnCongestionWindowChange, void(QuicTime now)); |
| 304 MOCK_METHOD1(OnConnectionMigration, void(PeerAddressChangeType type)); | 304 MOCK_METHOD1(OnConnectionMigration, void(PeerAddressChangeType type)); |
| 305 MOCK_METHOD0(OnPathDegrading, void()); | 305 MOCK_METHOD0(OnPathDegrading, void()); |
| 306 MOCK_CONST_METHOD0(WillingAndAbleToWrite, bool()); | 306 MOCK_CONST_METHOD0(WillingAndAbleToWrite, bool()); |
| 307 MOCK_CONST_METHOD0(HasPendingHandshake, bool()); | 307 MOCK_CONST_METHOD0(HasPendingHandshake, bool()); |
| 308 MOCK_CONST_METHOD0(HasOpenDynamicStreams, bool()); | 308 MOCK_CONST_METHOD0(HasOpenDynamicStreams, bool()); |
| 309 MOCK_METHOD1(OnSuccessfulVersionNegotiation, | 309 MOCK_METHOD1(OnSuccessfulVersionNegotiation, |
| 310 void(const QuicVersion& version)); | 310 void(const QuicVersion& version)); |
| 311 MOCK_METHOD0(OnConfigNegotiated, void()); | 311 MOCK_METHOD0(OnConfigNegotiated, void()); |
| 312 MOCK_METHOD0(PostProcessAfterData, void()); | 312 MOCK_METHOD0(PostProcessAfterData, void()); |
| 313 MOCK_METHOD0(OnAckNeedsRetransmittableFrame, void()); |
| 313 | 314 |
| 314 private: | 315 private: |
| 315 DISALLOW_COPY_AND_ASSIGN(MockQuicConnectionVisitor); | 316 DISALLOW_COPY_AND_ASSIGN(MockQuicConnectionVisitor); |
| 316 }; | 317 }; |
| 317 | 318 |
| 318 class MockQuicConnectionHelper : public QuicConnectionHelperInterface { | 319 class MockQuicConnectionHelper : public QuicConnectionHelperInterface { |
| 319 public: | 320 public: |
| 320 MockQuicConnectionHelper(); | 321 MockQuicConnectionHelper(); |
| 321 ~MockQuicConnectionHelper() override; | 322 ~MockQuicConnectionHelper() override; |
| 322 const QuicClock* GetClock() const override; | 323 const QuicClock* GetClock() const override; |
| (...skipping 671 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 994 iov->iov_base = const_cast<char*>(str.data()); | 995 iov->iov_base = const_cast<char*>(str.data()); |
| 995 iov->iov_len = static_cast<size_t>(str.size()); | 996 iov->iov_len = static_cast<size_t>(str.size()); |
| 996 QuicIOVector quic_iov(iov, 1, str.size()); | 997 QuicIOVector quic_iov(iov, 1, str.size()); |
| 997 return quic_iov; | 998 return quic_iov; |
| 998 } | 999 } |
| 999 | 1000 |
| 1000 } // namespace test | 1001 } // namespace test |
| 1001 } // namespace net | 1002 } // namespace net |
| 1002 | 1003 |
| 1003 #endif // NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ | 1004 #endif // NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ |
| OLD | NEW |