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

Side by Side Diff: net/quic/core/quic_spdy_stream_test.cc

Issue 2963763003: In QUIC, send data is copied to streams rather than frames. Protected by FLAGS_quic_reloadable_flag… (Closed)
Patch Set: Rebase Created 3 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 unified diff | Download patch
« no previous file with comments | « net/quic/core/quic_session.cc ('k') | net/quic/core/quic_stream.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/quic/core/quic_spdy_stream.h" 5 #include "net/quic/core/quic_spdy_stream.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility> 8 #include <utility>
9 9
10 #include "net/quic/core/quic_connection.h" 10 #include "net/quic/core/quic_connection.h"
(...skipping 955 matching lines...) Expand 10 before | Expand all | Expand 10 after
966 "Trailers cannot be sent after a FIN"); 966 "Trailers cannot be sent after a FIN");
967 } 967 }
968 968
969 TEST_P(QuicSpdyStreamTest, HeaderStreamNotiferCorrespondingSpdyStream) { 969 TEST_P(QuicSpdyStreamTest, HeaderStreamNotiferCorrespondingSpdyStream) {
970 Initialize(kShouldProcessData); 970 Initialize(kShouldProcessData);
971 if (!session_->use_stream_notifier()) { 971 if (!session_->use_stream_notifier()) {
972 return; 972 return;
973 } 973 }
974 EXPECT_CALL(*session_, WritevData(_, _, _, _, _, _)) 974 EXPECT_CALL(*session_, WritevData(_, _, _, _, _, _))
975 .Times(AnyNumber()) 975 .Times(AnyNumber())
976 .WillRepeatedly(Invoke(MockQuicSession::ConsumeAllData)); 976 .WillRepeatedly(
977 Invoke(session_.get(), &MockQuicSpdySession::ConsumeAndSaveAllData));
977 testing::InSequence s; 978 testing::InSequence s;
978 QuicReferenceCountedPointer<MockAckListener> ack_listener1( 979 QuicReferenceCountedPointer<MockAckListener> ack_listener1(
979 new MockAckListener()); 980 new MockAckListener());
980 QuicReferenceCountedPointer<MockAckListener> ack_listener2( 981 QuicReferenceCountedPointer<MockAckListener> ack_listener2(
981 new MockAckListener()); 982 new MockAckListener());
982 stream_->set_ack_listener(ack_listener1); 983 stream_->set_ack_listener(ack_listener1);
983 stream2_->set_ack_listener(ack_listener2); 984 stream2_->set_ack_listener(ack_listener2);
984 985
985 session_->headers_stream()->WriteOrBufferData("Header1", false, 986 session_->headers_stream()->WriteOrBufferData("Header1", false,
986 ack_listener1); 987 ack_listener1);
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
1023 // stream_ has unacked data and should become zombie. 1024 // stream_ has unacked data and should become zombie.
1024 EXPECT_TRUE(QuicContainsKey(QuicSessionPeer::zombie_streams(session_.get()), 1025 EXPECT_TRUE(QuicContainsKey(QuicSessionPeer::zombie_streams(session_.get()),
1025 stream_->id())); 1026 stream_->id()));
1026 EXPECT_TRUE(QuicSessionPeer::closed_streams(session_.get()).empty()); 1027 EXPECT_TRUE(QuicSessionPeer::closed_streams(session_.get()).empty());
1027 } 1028 }
1028 } 1029 }
1029 1030
1030 } // namespace 1031 } // namespace
1031 } // namespace test 1032 } // namespace test
1032 } // namespace net 1033 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/quic_session.cc ('k') | net/quic/core/quic_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698