mirror of
https://github.com/facebookincubator/mvfst.git
synced 2025-08-08 09:42:06 +03:00
Revert D15267820: [quic] Add unit test for sending RetireConnectionIdFrame
Differential Revision: D15267820 Original commit changeset: b885ca6b5dfa fbshipit-source-id: 899b6773521a347f06972d69e6be8456dc4e9e7d
This commit is contained in:
committed by
Facebook Github Bot
parent
52a79997d8
commit
2bdb9b0dcc
@@ -1483,33 +1483,6 @@ TEST_F(QuicTransportTest, ResendNewConnectionIdOnLoss) {
|
|||||||
[&](auto&) { return false; }));
|
[&](auto&) { return false; }));
|
||||||
}
|
}
|
||||||
|
|
||||||
TEST_F(QuicTransportTest, SendRetireConnectionIdFrame) {
|
|
||||||
EXPECT_CALL(*socket_, write(_, _)).WillOnce(Invoke(bufLength));
|
|
||||||
auto& conn = transport_->getConnectionState();
|
|
||||||
RetireConnectionIdFrame retireConnId(1);
|
|
||||||
sendSimpleFrame(conn, retireConnId);
|
|
||||||
transport_->updateWriteLooper(true);
|
|
||||||
loopForWrites();
|
|
||||||
|
|
||||||
EXPECT_TRUE(conn.pendingEvents.frames.empty());
|
|
||||||
EXPECT_EQ(1, transport_->getConnectionState().outstandingPackets.size());
|
|
||||||
auto packet =
|
|
||||||
getLastOutstandingPacket(
|
|
||||||
transport_->getConnectionState(), PacketNumberSpace::AppData)
|
|
||||||
->packet;
|
|
||||||
bool foundRetireConnectionId = false;
|
|
||||||
for (auto& simpleFrame : all_frames<QuicSimpleFrame>(packet.frames)) {
|
|
||||||
folly::variant_match(
|
|
||||||
simpleFrame,
|
|
||||||
[&](const RetireConnectionIdFrame& frame) {
|
|
||||||
EXPECT_EQ(frame, retireConnId);
|
|
||||||
foundRetireConnectionId = true;
|
|
||||||
},
|
|
||||||
[&](auto&) {});
|
|
||||||
}
|
|
||||||
EXPECT_TRUE(foundRetireConnectionId);
|
|
||||||
}
|
|
||||||
|
|
||||||
TEST_F(QuicTransportTest, NonWritableStreamAPI) {
|
TEST_F(QuicTransportTest, NonWritableStreamAPI) {
|
||||||
auto streamId = transport_->createBidirectionalStream().value();
|
auto streamId = transport_->createBidirectionalStream().value();
|
||||||
auto buf = buildRandomInputData(20);
|
auto buf = buildRandomInputData(20);
|
||||||
|
Reference in New Issue
Block a user