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

Side by Side Diff: net/quic/test_tools/quic_test_utils.h

Issue 420313005: Land Recent QUIC Changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Final_0723
Patch Set: change QUIC packet size to 1350 Created 6 years, 4 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
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 // 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 <string> 10 #include <string>
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 InFecGroup is_in_fec_group, 84 InFecGroup is_in_fec_group,
85 size_t* payload_length); 85 size_t* payload_length);
86 86
87 // Returns QuicConfig set to default values. 87 // Returns QuicConfig set to default values.
88 QuicConfig DefaultQuicConfig(); 88 QuicConfig DefaultQuicConfig();
89 89
90 // Returns a version vector consisting of |version|. 90 // Returns a version vector consisting of |version|.
91 QuicVersionVector SupportedVersions(QuicVersion version); 91 QuicVersionVector SupportedVersions(QuicVersion version);
92 92
93 // Testing convenience method to construct a QuicAckFrame with all packets 93 // Testing convenience method to construct a QuicAckFrame with all packets
94 // from least_unacked to largest_observed acked. 94 // from least_unacked to largest_observed acked.
wtc 2014/08/04 23:28:13 This comment needs updating because the "least_una
ramant (doing other things) 2014/08/09 02:53:19 Done.
95 QuicAckFrame MakeAckFrame(QuicPacketSequenceNumber largest_observed, 95 QuicAckFrame MakeAckFrame(QuicPacketSequenceNumber largest_observed);
96 QuicPacketSequenceNumber least_unacked);
97 96
98 // Testing convenience method to construct a QuicAckFrame with |num_nack_ranges| 97 // Testing convenience method to construct a QuicAckFrame with |num_nack_ranges|
99 // nack ranges of width 1 packet, starting from |least_unacked|. 98 // nack ranges of width 1 packet, starting from |least_unacked|.
100 QuicAckFrame MakeAckFrameWithNackRanges(size_t num_nack_ranges, 99 QuicAckFrame MakeAckFrameWithNackRanges(size_t num_nack_ranges,
101 QuicPacketSequenceNumber least_unacked); 100 QuicPacketSequenceNumber least_unacked);
102 101
103 // Returns a SerializedPacket whose |packet| member is owned by the caller, and 102 // Returns a SerializedPacket whose |packet| member is owned by the caller, and
104 // is populated with the fields in |header| and |frames|, or is NULL if the 103 // is populated with the fields in |header| and |frames|, or is NULL if the
105 // packet could not be created. 104 // packet could not be created.
106 SerializedPacket BuildUnsizedDataPacket(QuicFramer* framer, 105 SerializedPacket BuildUnsizedDataPacket(QuicFramer* framer,
(...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after
540 MOCK_METHOD1(OnCongestionWindowChange, void(QuicByteCount)); 539 MOCK_METHOD1(OnCongestionWindowChange, void(QuicByteCount));
541 540
542 private: 541 private:
543 DISALLOW_COPY_AND_ASSIGN(MockNetworkChangeVisitor); 542 DISALLOW_COPY_AND_ASSIGN(MockNetworkChangeVisitor);
544 }; 543 };
545 544
546 } // namespace test 545 } // namespace test
547 } // namespace net 546 } // namespace net
548 547
549 #endif // NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_ 548 #endif // NET_QUIC_TEST_TOOLS_QUIC_TEST_UTILS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698