| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/quic_stream_sequencer.h" | 5 #include "net/quic/quic_stream_sequencer.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 MockStream(QuicSession* session, QuicStreamId id) | 37 MockStream(QuicSession* session, QuicStreamId id) |
| 38 : ReliableQuicStream(id, session) { | 38 : ReliableQuicStream(id, session) { |
| 39 } | 39 } |
| 40 | 40 |
| 41 MOCK_METHOD0(OnFinRead, void()); | 41 MOCK_METHOD0(OnFinRead, void()); |
| 42 MOCK_METHOD2(ProcessRawData, uint32(const char* data, uint32 data_len)); | 42 MOCK_METHOD2(ProcessRawData, uint32(const char* data, uint32 data_len)); |
| 43 MOCK_METHOD2(CloseConnectionWithDetails, void(QuicErrorCode error, | 43 MOCK_METHOD2(CloseConnectionWithDetails, void(QuicErrorCode error, |
| 44 const string& details)); | 44 const string& details)); |
| 45 MOCK_METHOD1(Reset, void(QuicRstStreamErrorCode error)); | 45 MOCK_METHOD1(Reset, void(QuicRstStreamErrorCode error)); |
| 46 MOCK_METHOD0(OnCanWrite, void()); | 46 MOCK_METHOD0(OnCanWrite, void()); |
| 47 virtual QuicPriority EffectivePriority() const override { | 47 QuicPriority EffectivePriority() const override { |
| 48 return QuicUtils::HighestPriority(); | 48 return QuicUtils::HighestPriority(); |
| 49 } | 49 } |
| 50 virtual bool IsFlowControlEnabled() const { | 50 virtual bool IsFlowControlEnabled() const { |
| 51 return true; | 51 return true; |
| 52 } | 52 } |
| 53 }; | 53 }; |
| 54 | 54 |
| 55 namespace { | 55 namespace { |
| 56 | 56 |
| 57 static const char kPayload[] = | 57 static const char kPayload[] = |
| (...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 436 QuicStreamFrame frame2(kClientDataStreamId1, false, 2, MakeIOVector("hello")); | 436 QuicStreamFrame frame2(kClientDataStreamId1, false, 2, MakeIOVector("hello")); |
| 437 EXPECT_TRUE(sequencer_->FrameOverlapsBufferedData(frame2)); | 437 EXPECT_TRUE(sequencer_->FrameOverlapsBufferedData(frame2)); |
| 438 EXPECT_CALL(stream_, CloseConnectionWithDetails(QUIC_INVALID_STREAM_FRAME, _)) | 438 EXPECT_CALL(stream_, CloseConnectionWithDetails(QUIC_INVALID_STREAM_FRAME, _)) |
| 439 .Times(1); | 439 .Times(1); |
| 440 sequencer_->OnStreamFrame(frame2); | 440 sequencer_->OnStreamFrame(frame2); |
| 441 } | 441 } |
| 442 | 442 |
| 443 } // namespace | 443 } // namespace |
| 444 } // namespace test | 444 } // namespace test |
| 445 } // namespace net | 445 } // namespace net |
| OLD | NEW |