| 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 740 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 751 const CongestionVector& lost_packets)); | 751 const CongestionVector& lost_packets)); |
| 752 MOCK_METHOD5(OnPacketSent, | 752 MOCK_METHOD5(OnPacketSent, |
| 753 bool(QuicTime, | 753 bool(QuicTime, |
| 754 QuicByteCount, | 754 QuicByteCount, |
| 755 QuicPacketNumber, | 755 QuicPacketNumber, |
| 756 QuicByteCount, | 756 QuicByteCount, |
| 757 HasRetransmittableData)); | 757 HasRetransmittableData)); |
| 758 MOCK_METHOD1(OnRetransmissionTimeout, void(bool)); | 758 MOCK_METHOD1(OnRetransmissionTimeout, void(bool)); |
| 759 MOCK_METHOD0(OnConnectionMigration, void()); | 759 MOCK_METHOD0(OnConnectionMigration, void()); |
| 760 MOCK_METHOD0(RevertRetransmissionTimeout, void()); | 760 MOCK_METHOD0(RevertRetransmissionTimeout, void()); |
| 761 MOCK_CONST_METHOD2(TimeUntilSend, | 761 MOCK_METHOD2(TimeUntilSend, |
| 762 QuicTime::Delta(QuicTime now, | 762 QuicTime::Delta(QuicTime now, QuicByteCount bytes_in_flight)); |
| 763 QuicByteCount bytes_in_flight)); | |
| 764 MOCK_CONST_METHOD1(PacingRate, QuicBandwidth(QuicByteCount)); | 763 MOCK_CONST_METHOD1(PacingRate, QuicBandwidth(QuicByteCount)); |
| 765 MOCK_CONST_METHOD0(BandwidthEstimate, QuicBandwidth(void)); | 764 MOCK_CONST_METHOD0(BandwidthEstimate, QuicBandwidth(void)); |
| 766 MOCK_CONST_METHOD0(HasReliableBandwidthEstimate, bool()); | 765 MOCK_CONST_METHOD0(HasReliableBandwidthEstimate, bool()); |
| 767 MOCK_METHOD1(OnRttUpdated, void(QuicPacketNumber)); | 766 MOCK_METHOD1(OnRttUpdated, void(QuicPacketNumber)); |
| 768 MOCK_CONST_METHOD0(GetCongestionWindow, QuicByteCount()); | 767 MOCK_CONST_METHOD0(GetCongestionWindow, QuicByteCount()); |
| 769 MOCK_CONST_METHOD0(GetDebugState, std::string()); | 768 MOCK_CONST_METHOD0(GetDebugState, std::string()); |
| 770 MOCK_CONST_METHOD0(InSlowStart, bool()); | 769 MOCK_CONST_METHOD0(InSlowStart, bool()); |
| 771 MOCK_CONST_METHOD0(InRecovery, bool()); | 770 MOCK_CONST_METHOD0(InRecovery, bool()); |
| 772 MOCK_CONST_METHOD0(GetSlowStartThreshold, QuicByteCount()); | 771 MOCK_CONST_METHOD0(GetSlowStartThreshold, QuicByteCount()); |
| 773 MOCK_CONST_METHOD0(GetCongestionControlType, CongestionControlType()); | 772 MOCK_CONST_METHOD0(GetCongestionControlType, CongestionControlType()); |
| (...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 995 iov->iov_base = const_cast<char*>(str.data()); | 994 iov->iov_base = const_cast<char*>(str.data()); |
| 996 iov->iov_len = static_cast<size_t>(str.size()); | 995 iov->iov_len = static_cast<size_t>(str.size()); |
| 997 QuicIOVector quic_iov(iov, 1, str.size()); | 996 QuicIOVector quic_iov(iov, 1, str.size()); |
| 998 return quic_iov; | 997 return quic_iov; |
| 999 } | 998 } |
| 1000 | 999 |
| 1001 } // namespace test | 1000 } // namespace test |
| 1002 } // namespace net | 1001 } // namespace net |
| 1003 | 1002 |
| 1004 #endif // NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ | 1003 #endif // NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ |
| OLD | NEW |