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

Side by Side Diff: net/quic/core/quic_packet_generator_test.cc

Issue 2236973002: Landing Recent QUIC changes until 4AM, Aug 7, 2016 UTC-4 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: flip quic_sequencer_buffer_retire_block_in_time to true Created 4 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
« no previous file with comments | « net/quic/core/quic_packet_creator_test.cc ('k') | net/quic/core/quic_protocol.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/quic/core/quic_packet_generator.h" 5 #include "net/quic/core/quic_packet_generator.h"
6 6
7 #include <cstdint> 7 #include <cstdint>
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 10
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 size_t num_stream_frames; 97 size_t num_stream_frames;
98 size_t num_ping_frames; 98 size_t num_ping_frames;
99 size_t num_mtu_discovery_frames; 99 size_t num_mtu_discovery_frames;
100 }; 100 };
101 101
102 } // namespace 102 } // namespace
103 103
104 class QuicPacketGeneratorTest : public ::testing::Test { 104 class QuicPacketGeneratorTest : public ::testing::Test {
105 public: 105 public:
106 QuicPacketGeneratorTest() 106 QuicPacketGeneratorTest()
107 : framer_(QuicSupportedVersions(), 107 : framer_(AllSupportedVersions(),
108 QuicTime::Zero(), 108 QuicTime::Zero(),
109 Perspective::IS_CLIENT), 109 Perspective::IS_CLIENT),
110 generator_(42, &framer_, &random_, &buffer_allocator_, &delegate_), 110 generator_(42, &framer_, &random_, &buffer_allocator_, &delegate_),
111 creator_(QuicPacketGeneratorPeer::GetPacketCreator(&generator_)) { 111 creator_(QuicPacketGeneratorPeer::GetPacketCreator(&generator_)) {
112 // TODO(ianswett): Fix this test so it uses a non-null encrypter. 112 // TODO(ianswett): Fix this test so it uses a non-null encrypter.
113 FLAGS_quic_never_write_unencrypted_data = false; 113 FLAGS_quic_never_write_unencrypted_data = false;
114 } 114 }
115 115
116 ~QuicPacketGeneratorTest() override { 116 ~QuicPacketGeneratorTest() override {
117 for (SerializedPacket& packet : packets_) { 117 for (SerializedPacket& packet : packets_) {
(...skipping 753 matching lines...) Expand 10 before | Expand all | Expand 10 after
871 EXPECT_CALL(delegate_, OnSerializedPacket(_)) 871 EXPECT_CALL(delegate_, OnSerializedPacket(_))
872 .WillOnce(Invoke(this, &QuicPacketGeneratorTest::SavePacket)); 872 .WillOnce(Invoke(this, &QuicPacketGeneratorTest::SavePacket));
873 generator_.FlushAllQueuedFrames(); 873 generator_.FlushAllQueuedFrames();
874 EXPECT_FALSE(generator_.HasQueuedFrames()); 874 EXPECT_FALSE(generator_.HasQueuedFrames());
875 generator_.SetCurrentPath(kTestPathId1, 1, 0); 875 generator_.SetCurrentPath(kTestPathId1, 1, 0);
876 EXPECT_EQ(kTestPathId1, QuicPacketCreatorPeer::GetCurrentPath(creator_)); 876 EXPECT_EQ(kTestPathId1, QuicPacketCreatorPeer::GetCurrentPath(creator_));
877 } 877 }
878 878
879 } // namespace test 879 } // namespace test
880 } // namespace net 880 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/quic_packet_creator_test.cc ('k') | net/quic/core/quic_protocol.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698