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

Side by Side Diff: net/spdy/spdy_stream_test_util.cc

Issue 2102253003: Make SpdyHeaderBlock non-copyable. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: iOS fix. Created 4 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/spdy/spdy_stream.cc ('k') | net/spdy/spdy_stream_unittest.cc » ('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 (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/spdy/spdy_stream_test_util.h" 5 #include "net/spdy/spdy_stream_test_util.h"
6 6
7 #include <cstddef> 7 #include <cstddef>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 54
55 void StreamDelegateBase::OnRequestHeadersSent() { 55 void StreamDelegateBase::OnRequestHeadersSent() {
56 stream_id_ = stream_->stream_id(); 56 stream_id_ = stream_->stream_id();
57 EXPECT_NE(stream_id_, 0u); 57 EXPECT_NE(stream_id_, 0u);
58 send_headers_completed_ = true; 58 send_headers_completed_ = true;
59 } 59 }
60 60
61 SpdyResponseHeadersStatus StreamDelegateBase::OnResponseHeadersUpdated( 61 SpdyResponseHeadersStatus StreamDelegateBase::OnResponseHeadersUpdated(
62 const SpdyHeaderBlock& response_headers) { 62 const SpdyHeaderBlock& response_headers) {
63 EXPECT_EQ(stream_->type() != SPDY_PUSH_STREAM, send_headers_completed_); 63 EXPECT_EQ(stream_->type() != SPDY_PUSH_STREAM, send_headers_completed_);
64 response_headers_ = response_headers; 64 response_headers_ = response_headers.Clone();
65 return RESPONSE_HEADERS_ARE_COMPLETE; 65 return RESPONSE_HEADERS_ARE_COMPLETE;
66 } 66 }
67 67
68 void StreamDelegateBase::OnDataReceived(std::unique_ptr<SpdyBuffer> buffer) { 68 void StreamDelegateBase::OnDataReceived(std::unique_ptr<SpdyBuffer> buffer) {
69 if (buffer) 69 if (buffer)
70 received_data_queue_.Enqueue(std::move(buffer)); 70 received_data_queue_.Enqueue(std::move(buffer));
71 } 71 }
72 72
73 void StreamDelegateBase::OnDataSent() {} 73 void StreamDelegateBase::OnDataSent() {}
74 74
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 SpdyResponseHeadersStatus 158 SpdyResponseHeadersStatus
159 StreamDelegateCloseOnHeaders::OnResponseHeadersUpdated( 159 StreamDelegateCloseOnHeaders::OnResponseHeadersUpdated(
160 const SpdyHeaderBlock& response_headers) { 160 const SpdyHeaderBlock& response_headers) {
161 stream()->Cancel(); 161 stream()->Cancel();
162 return RESPONSE_HEADERS_ARE_COMPLETE; 162 return RESPONSE_HEADERS_ARE_COMPLETE;
163 } 163 }
164 164
165 } // namespace test 165 } // namespace test
166 166
167 } // namespace net 167 } // namespace net
OLDNEW
« no previous file with comments | « net/spdy/spdy_stream.cc ('k') | net/spdy/spdy_stream_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698