| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/chromium/bidirectional_stream_quic_impl.h" | 5 #include "net/quic/chromium/bidirectional_stream_quic_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/callback_helpers.h" | 9 #include "base/callback_helpers.h" |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| (...skipping 1694 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1705 EXPECT_EQ(1, delegate->on_data_read_count()); | 1705 EXPECT_EQ(1, delegate->on_data_read_count()); |
| 1706 EXPECT_EQ(0, delegate->on_data_sent_count()); | 1706 EXPECT_EQ(0, delegate->on_data_sent_count()); |
| 1707 } | 1707 } |
| 1708 | 1708 |
| 1709 TEST_P(BidirectionalStreamQuicImplTest, DeleteStreamDuringOnTrailersReceived) { | 1709 TEST_P(BidirectionalStreamQuicImplTest, DeleteStreamDuringOnTrailersReceived) { |
| 1710 SetRequest("GET", "/", DEFAULT_PRIORITY); | 1710 SetRequest("GET", "/", DEFAULT_PRIORITY); |
| 1711 size_t spdy_request_headers_frame_length; | 1711 size_t spdy_request_headers_frame_length; |
| 1712 AddWrite(ConstructRequestHeadersPacket(1, kFin, DEFAULT_PRIORITY, | 1712 AddWrite(ConstructRequestHeadersPacket(1, kFin, DEFAULT_PRIORITY, |
| 1713 &spdy_request_headers_frame_length)); | 1713 &spdy_request_headers_frame_length)); |
| 1714 AddWrite(ConstructClientAckPacket(2, 3, 1)); // Ack the data packet | 1714 AddWrite(ConstructClientAckPacket(2, 3, 1)); // Ack the data packet |
| 1715 AddWrite(ConstructClientAckAndRstStreamPacket(3, 4, 4, 1)); |
| 1715 | 1716 |
| 1716 Initialize(); | 1717 Initialize(); |
| 1717 | 1718 |
| 1718 BidirectionalStreamRequestInfo request; | 1719 BidirectionalStreamRequestInfo request; |
| 1719 request.method = "GET"; | 1720 request.method = "GET"; |
| 1720 request.url = GURL("http://www.google.com/"); | 1721 request.url = GURL("http://www.google.com/"); |
| 1721 request.end_stream_on_headers = true; | 1722 request.end_stream_on_headers = true; |
| 1722 request.priority = DEFAULT_PRIORITY; | 1723 request.priority = DEFAULT_PRIORITY; |
| 1723 | 1724 |
| 1724 scoped_refptr<IOBuffer> read_buffer(new IOBuffer(kReadBufferSize)); | 1725 scoped_refptr<IOBuffer> read_buffer(new IOBuffer(kReadBufferSize)); |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1769 | 1770 |
| 1770 base::RunLoop().RunUntilIdle(); | 1771 base::RunLoop().RunUntilIdle(); |
| 1771 | 1772 |
| 1772 EXPECT_EQ(1, delegate->on_data_read_count()); | 1773 EXPECT_EQ(1, delegate->on_data_read_count()); |
| 1773 EXPECT_EQ(0, delegate->on_data_sent_count()); | 1774 EXPECT_EQ(0, delegate->on_data_sent_count()); |
| 1774 } | 1775 } |
| 1775 | 1776 |
| 1776 } // namespace test | 1777 } // namespace test |
| 1777 | 1778 |
| 1778 } // namespace net | 1779 } // namespace net |
| OLD | NEW |