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

Unified Diff: net/quic/core/quic_stream_sequencer_buffer_test.cc

Issue 2519333006: Add CHECK's to debug QuicStreamSequencerBuffer in weird state. Add a destruction indicator to detec… (Closed)
Patch Set: using CHECK_GT Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/core/quic_stream_sequencer_buffer.cc ('k') | net/quic/core/quic_stream_sequencer_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/core/quic_stream_sequencer_buffer_test.cc
diff --git a/net/quic/core/quic_stream_sequencer_buffer_test.cc b/net/quic/core/quic_stream_sequencer_buffer_test.cc
index bc3025d42ac48c69a6b4ab17f09c1d24f8dca7a0..919da24517568d58e343bcb368eaa70ecab54f8f 100644
--- a/net/quic/core/quic_stream_sequencer_buffer_test.cc
+++ b/net/quic/core/quic_stream_sequencer_buffer_test.cc
@@ -332,26 +332,6 @@ TEST_F(QuicStreamSequencerBufferTest, Readv100Bytes) {
EXPECT_TRUE(helper_->CheckBufferInvariants());
}
-TEST_F(QuicStreamSequencerBufferTest, ReadvError) {
- string source = string(100, 'b');
- clock_.AdvanceTime(QuicTime::Delta::FromSeconds(1));
- QuicTime t1 = clock_.ApproximateNow();
- // Write something into [0, 100).
- size_t written;
- buffer_->OnStreamData(0, source, t1, &written, &error_details_);
- EXPECT_TRUE(helper_->GetBlock(0) != nullptr);
- EXPECT_TRUE(buffer_->HasBytesToRead());
- // Read into a iovec array with total capacity of 120 bytes.
- iovec iov{nullptr, 120};
- size_t read;
- EXPECT_EQ(QUIC_STREAM_SEQUENCER_INVALID_STATE,
- buffer_->Readv(&iov, 1, &read, &error_details_));
- EXPECT_EQ(0u,
- error_details_.find(
- "QuicStreamSequencerBuffer error: Readv() dest == nullptr: true"
- " blocks_[0] == nullptr: false"));
-}
-
TEST_F(QuicStreamSequencerBufferTest, ReadvAcrossBlocks) {
string source(kBlockSizeBytes + 50, 'a');
// Write 1st block to full and extand 50 bytes to next block.
« no previous file with comments | « net/quic/core/quic_stream_sequencer_buffer.cc ('k') | net/quic/core/quic_stream_sequencer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698