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

Side by Side Diff: net/tools/quic/quic_dispatcher_test.cc

Issue 2846003002: Deprecate FLAGS_quic_reloadable_flag_quic_remove_packet_number_from_public_reset. (Closed)
Patch Set: remove the deprecated flag Created 3 years, 7 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/tools/quic/end_to_end_test.cc ('k') | net/tools/quic/quic_time_wait_list_manager.cc » ('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/tools/quic/quic_dispatcher.h" 5 #include "net/tools/quic/quic_dispatcher.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <ostream> 8 #include <ostream>
9 #include <string> 9 #include <string>
10 10
(...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
421 .WillOnce(testing::WithArgs<2>(Invoke(CreateFunctor( 421 .WillOnce(testing::WithArgs<2>(Invoke(CreateFunctor(
422 &QuicDispatcherTest::ValidatePacket, base::Unretained(this), 1)))); 422 &QuicDispatcherTest::ValidatePacket, base::Unretained(this), 1))));
423 423
424 ProcessPacket(client_address, connection_id, true, SerializeCHLO()); 424 ProcessPacket(client_address, connection_id, true, SerializeCHLO());
425 425
426 // Close the connection by sending public reset packet. 426 // Close the connection by sending public reset packet.
427 QuicPublicResetPacket packet; 427 QuicPublicResetPacket packet;
428 packet.public_header.connection_id = connection_id; 428 packet.public_header.connection_id = connection_id;
429 packet.public_header.reset_flag = true; 429 packet.public_header.reset_flag = true;
430 packet.public_header.version_flag = false; 430 packet.public_header.version_flag = false;
431 packet.rejected_packet_number = 19191;
432 packet.nonce_proof = 132232; 431 packet.nonce_proof = 132232;
433 std::unique_ptr<QuicEncryptedPacket> encrypted( 432 std::unique_ptr<QuicEncryptedPacket> encrypted(
434 QuicFramer::BuildPublicResetPacket(packet)); 433 QuicFramer::BuildPublicResetPacket(packet));
435 std::unique_ptr<QuicReceivedPacket> received(ConstructReceivedPacket( 434 std::unique_ptr<QuicReceivedPacket> received(ConstructReceivedPacket(
436 *encrypted, session1_->connection()->clock()->Now())); 435 *encrypted, session1_->connection()->clock()->Now()));
437 EXPECT_CALL(*session1_, OnConnectionClosed(QUIC_PUBLIC_RESET, _, 436 EXPECT_CALL(*session1_, OnConnectionClosed(QUIC_PUBLIC_RESET, _,
438 ConnectionCloseSource::FROM_PEER)) 437 ConnectionCloseSource::FROM_PEER))
439 .Times(1) 438 .Times(1)
440 .WillOnce(WithoutArgs(Invoke( 439 .WillOnce(WithoutArgs(Invoke(
441 reinterpret_cast<MockServerConnection*>(session1_->connection()), 440 reinterpret_cast<MockServerConnection*>(session1_->connection()),
(...skipping 1601 matching lines...) Expand 10 before | Expand all | Expand 10 after
2043 check.Call(2); 2042 check.Call(2);
2044 GetFakeProofSource()->InvokePendingCallback(0); 2043 GetFakeProofSource()->InvokePendingCallback(0);
2045 ASSERT_EQ(GetFakeProofSource()->NumPendingCallbacks(), 0); 2044 ASSERT_EQ(GetFakeProofSource()->NumPendingCallbacks(), 0);
2046 EXPECT_FALSE(store->HasBufferedPackets(conn_id)); 2045 EXPECT_FALSE(store->HasBufferedPackets(conn_id));
2047 EXPECT_FALSE(time_wait_list_manager_->IsConnectionIdInTimeWait(conn_id)); 2046 EXPECT_FALSE(time_wait_list_manager_->IsConnectionIdInTimeWait(conn_id));
2048 } 2047 }
2049 2048
2050 } // namespace 2049 } // namespace
2051 } // namespace test 2050 } // namespace test
2052 } // namespace net 2051 } // namespace net
OLDNEW
« no previous file with comments | « net/tools/quic/end_to_end_test.cc ('k') | net/tools/quic/quic_time_wait_list_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698