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

Unified Diff: net/quic/quic_http_stream_test.cc

Issue 531903002: Merge f9f103cbc943019e6576a68c724a6360da26b687 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2125
Patch Set: Created 6 years, 3 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_http_stream.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_http_stream_test.cc
diff --git a/net/quic/quic_http_stream_test.cc b/net/quic/quic_http_stream_test.cc
index 932f566d4a525c7efbc299e83188c6fc7177028a..786ed496ee8714ff07845ecf5b970c15ed9c054e 100644
--- a/net/quic/quic_http_stream_test.cc
+++ b/net/quic/quic_http_stream_test.cc
@@ -427,6 +427,24 @@ TEST_P(QuicHttpStreamTest, GetRequestLargeResponse) {
EXPECT_TRUE(AtEof());
}
+// Regression test for http://crbug.com/409101
+TEST_P(QuicHttpStreamTest, SessionClosedBeforeSendRequest) {
+ SetRequest("GET", "/", DEFAULT_PRIORITY);
+ Initialize();
+
+ request_.method = "GET";
+ request_.url = GURL("http://www.google.com/");
+
+ EXPECT_EQ(OK, stream_->InitializeStream(&request_, DEFAULT_PRIORITY,
+ net_log_, callback_.callback()));
+
+ session_->connection()->CloseConnection(QUIC_NO_ERROR, true);
+
+ EXPECT_EQ(ERR_CONNECTION_CLOSED,
+ stream_->SendRequest(headers_, &response_,
+ callback_.callback()));
+}
+
TEST_P(QuicHttpStreamTest, SendPostRequest) {
SetRequest("POST", "/", DEFAULT_PRIORITY);
AddWrite(ConstructRequestHeadersPacket(1, !kFin));
« no previous file with comments | « net/quic/quic_http_stream.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698