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

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

Issue 2675593002: Spdy{RstStream,GoAway}Status -> SpdyErrorCode. (Closed)
Patch Set: Merged master, which includes 145087791. Created 3 years, 10 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_protocol.cc ('k') | net/spdy/spdy_proxy_client_socket.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 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 <stdint.h> 5 #include <stdint.h>
6 6
7 #include "net/spdy/spdy_protocol_test_utils.h" 7 #include "net/spdy/spdy_protocol_test_utils.h"
8 8
9 namespace net { 9 namespace net {
10 namespace test { 10 namespace test {
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 return ::testing::AssertionFailure(); 59 return ::testing::AssertionFailure();
60 60
61 return ::testing::AssertionSuccess(); 61 return ::testing::AssertionSuccess();
62 } 62 }
63 63
64 ::testing::AssertionResult VerifySpdyFrameIREquals(const SpdyGoAwayIR& expected, 64 ::testing::AssertionResult VerifySpdyFrameIREquals(const SpdyGoAwayIR& expected,
65 const SpdyGoAwayIR& actual) { 65 const SpdyGoAwayIR& actual) {
66 DVLOG(1) << "VerifySpdyFrameIREquals SpdyGoAwayIR"; 66 DVLOG(1) << "VerifySpdyFrameIREquals SpdyGoAwayIR";
67 if (expected.last_good_stream_id() != actual.last_good_stream_id()) 67 if (expected.last_good_stream_id() != actual.last_good_stream_id())
68 return ::testing::AssertionFailure(); 68 return ::testing::AssertionFailure();
69 if (expected.status() != actual.status()) 69 if (expected.error_code() != actual.error_code())
70 return ::testing::AssertionFailure(); 70 return ::testing::AssertionFailure();
71 if (expected.description() != actual.description()) 71 if (expected.description() != actual.description())
72 return ::testing::AssertionFailure(); 72 return ::testing::AssertionFailure();
73 73
74 return ::testing::AssertionSuccess(); 74 return ::testing::AssertionSuccess();
75 } 75 }
76 76
77 ::testing::AssertionResult VerifySpdyFrameIREquals( 77 ::testing::AssertionResult VerifySpdyFrameIREquals(
78 const SpdyHeadersIR& expected, 78 const SpdyHeadersIR& expected,
79 const SpdyHeadersIR& actual) { 79 const SpdyHeadersIR& actual) {
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 134
135 return ::testing::AssertionSuccess(); 135 return ::testing::AssertionSuccess();
136 } 136 }
137 137
138 ::testing::AssertionResult VerifySpdyFrameIREquals( 138 ::testing::AssertionResult VerifySpdyFrameIREquals(
139 const SpdyRstStreamIR& expected, 139 const SpdyRstStreamIR& expected,
140 const SpdyRstStreamIR& actual) { 140 const SpdyRstStreamIR& actual) {
141 DVLOG(1) << "VerifySpdyFrameIREquals SpdyRstStreamIR"; 141 DVLOG(1) << "VerifySpdyFrameIREquals SpdyRstStreamIR";
142 if (expected.stream_id() != actual.stream_id()) 142 if (expected.stream_id() != actual.stream_id())
143 return ::testing::AssertionFailure(); 143 return ::testing::AssertionFailure();
144 if (expected.status() != actual.status()) 144 if (expected.error_code() != actual.error_code())
145 return ::testing::AssertionFailure(); 145 return ::testing::AssertionFailure();
146 146
147 return ::testing::AssertionSuccess(); 147 return ::testing::AssertionSuccess();
148 } 148 }
149 149
150 ::testing::AssertionResult VerifySpdyFrameIREquals( 150 ::testing::AssertionResult VerifySpdyFrameIREquals(
151 const SpdySettingsIR& expected, 151 const SpdySettingsIR& expected,
152 const SpdySettingsIR& actual) { 152 const SpdySettingsIR& actual) {
153 DVLOG(1) << "VerifySpdyFrameIREquals SpdySettingsIR"; 153 DVLOG(1) << "VerifySpdyFrameIREquals SpdySettingsIR";
154 // Note, ignoring non-HTTP/2 fields such as clear_settings. 154 // Note, ignoring non-HTTP/2 fields such as clear_settings.
(...skipping 27 matching lines...) Expand all
182 if (expected.stream_id() != actual.stream_id()) 182 if (expected.stream_id() != actual.stream_id())
183 return ::testing::AssertionFailure(); 183 return ::testing::AssertionFailure();
184 if (expected.delta() != actual.delta()) 184 if (expected.delta() != actual.delta())
185 return ::testing::AssertionFailure(); 185 return ::testing::AssertionFailure();
186 186
187 return ::testing::AssertionSuccess(); 187 return ::testing::AssertionSuccess();
188 } 188 }
189 189
190 } // namespace test 190 } // namespace test
191 } // namespace net 191 } // namespace net
OLDNEW
« no previous file with comments | « net/spdy/spdy_protocol.cc ('k') | net/spdy/spdy_proxy_client_socket.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698