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

Unified Diff: net/quic/quic_session_test.cc

Issue 664803003: Update from chromium a8e7c94b1b79a0948d05a1fcfff53391d22ce37a (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 2 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_reliable_client_stream.cc ('k') | net/quic/quic_stream_factory.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_session_test.cc
diff --git a/net/quic/quic_session_test.cc b/net/quic/quic_session_test.cc
index 0a5032e70885846adb43ec89de5e6c7415a9c675..471262072c0532c287d0297ad311af1dedc8fdfc 100644
--- a/net/quic/quic_session_test.cc
+++ b/net/quic/quic_session_test.cc
@@ -729,23 +729,26 @@ TEST_P(QuicSessionTest, HandshakeUnblocksFlowControlBlockedHeadersStream) {
EXPECT_FALSE(session_.IsStreamFlowControlBlocked());
QuicStreamId stream_id = 5;
// Write until the header stream is flow control blocked.
+ SpdyHeaderBlock headers;
while (!headers_stream->flow_controller()->IsBlocked() && stream_id < 2010) {
EXPECT_FALSE(session_.IsConnectionFlowControlBlocked());
EXPECT_FALSE(session_.IsStreamFlowControlBlocked());
- SpdyHeaderBlock headers;
headers["header"] = base::Uint64ToString(base::RandUint64()) +
base::Uint64ToString(base::RandUint64()) +
base::Uint64ToString(base::RandUint64());
headers_stream->WriteHeaders(stream_id, headers, true, nullptr);
stream_id += 2;
}
+ // Write one more to ensure that the headers stream has buffered data. The
+ // random headers may have exactly filled the flow control window.
+ headers_stream->WriteHeaders(stream_id, headers, true, nullptr);
+ EXPECT_TRUE(headers_stream->HasBufferedData());
+
EXPECT_TRUE(headers_stream->flow_controller()->IsBlocked());
EXPECT_FALSE(crypto_stream->flow_controller()->IsBlocked());
EXPECT_FALSE(session_.IsConnectionFlowControlBlocked());
EXPECT_TRUE(session_.IsStreamFlowControlBlocked());
EXPECT_FALSE(session_.HasDataToWrite());
- // TODO(rtenneti): crbug.com/423586 headers_stream->HasBufferedData is flaky.
- // EXPECT_TRUE(headers_stream->HasBufferedData());
// Now complete the crypto handshake, resulting in an increased flow control
// send window.
« no previous file with comments | « net/quic/quic_reliable_client_stream.cc ('k') | net/quic/quic_stream_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698