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

Unified Diff: net/quic/quic_spdy_stream_test.cc

Issue 2115033002: Adds QUIC_VERSION_36 which adds support to force HOL blocking between streams for measurement purpo… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@126085461
Patch Set: typo Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_spdy_stream.cc ('k') | net/quic/reliable_quic_stream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_spdy_stream_test.cc
diff --git a/net/quic/quic_spdy_stream_test.cc b/net/quic/quic_spdy_stream_test.cc
index a869ded8911beb3ed4333a85ace3a177689b3c26..94be546be476ed3a329fd697f6348c2efac7f1c4 100644
--- a/net/quic/quic_spdy_stream_test.cc
+++ b/net/quic/quic_spdy_stream_test.cc
@@ -444,7 +444,7 @@ TEST_P(QuicSpdyStreamTest, StreamFlowControlBlocked) {
GenerateBody(&body, kWindow + kOverflow);
EXPECT_CALL(*connection_, SendBlocked(kClientDataStreamId1));
- EXPECT_CALL(*session_, WritevData(stream_, kClientDataStreamId1, _, _, _, _))
+ EXPECT_CALL(*session_, WritevData(_, _, _, _, _, _))
.WillOnce(Return(QuicConsumedData(kWindow, true)));
stream_->WriteOrBufferData(body, false, nullptr);
@@ -690,7 +690,7 @@ TEST_P(QuicSpdyStreamTest, StreamFlowControlFinNotBlocked) {
bool fin = true;
EXPECT_CALL(*connection_, SendBlocked(kClientDataStreamId1)).Times(0);
- EXPECT_CALL(*session_, WritevData(stream_, kClientDataStreamId1, _, _, _, _))
+ EXPECT_CALL(*session_, WritevData(_, _, _, _, _, _))
.WillOnce(Return(QuicConsumedData(0, fin)));
stream_->WriteOrBufferData(body, fin, nullptr);
@@ -966,14 +966,18 @@ TEST_P(QuicSpdyStreamTest, WritingTrailersWithQueuedBytes) {
EXPECT_CALL(*session_, WritevData(_, _, _, _, _, _))
.WillOnce(Return(QuicConsumedData(kBodySize - 1, false)));
stream_->WriteOrBufferData(string(kBodySize, 'x'), false, nullptr);
- EXPECT_EQ(1u, stream_->queued_data_bytes());
+ if (!session_->force_hol_blocking()) {
+ EXPECT_EQ(1u, stream_->queued_data_bytes());
+ }
// Writing trailers will send a FIN, but not close the write side of the
// stream as there are queued bytes.
EXPECT_CALL(*session_, WriteHeadersMock(_, _, true, _, _));
stream_->WriteTrailers(SpdyHeaderBlock(), nullptr);
EXPECT_TRUE(stream_->fin_sent());
- EXPECT_FALSE(stream_->write_side_closed());
+ if (!session_->force_hol_blocking()) {
+ EXPECT_FALSE(stream_->write_side_closed());
+ }
}
TEST_P(QuicSpdyStreamTest, WritingTrailersAfterFIN) {
« no previous file with comments | « net/quic/quic_spdy_stream.cc ('k') | net/quic/reliable_quic_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698