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

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

Issue 12259003: Clean up the last remaining bits of SpdySynReplyControlFrame. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
« no previous file with comments | « net/spdy/spdy_protocol.h ('k') | no next file » | 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_protocol.h" 5 #include "net/spdy/spdy_protocol.h"
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "net/spdy/spdy_bitmasks.h" 8 #include "net/spdy/spdy_bitmasks.h"
9 #include "net/spdy/spdy_framer.h" 9 #include "net/spdy/spdy_framer.h"
10 #include "testing/platform_test.h" 10 #include "testing/platform_test.h"
(...skipping 26 matching lines...) Expand all
37 INSTANTIATE_TEST_CASE_P(SpdyProtocolTests, 37 INSTANTIATE_TEST_CASE_P(SpdyProtocolTests,
38 SpdyProtocolTest, 38 SpdyProtocolTest,
39 ::testing::Values(SPDY2, SPDY3)); 39 ::testing::Values(SPDY2, SPDY3));
40 40
41 // Test our protocol constants 41 // Test our protocol constants
42 TEST_P(SpdyProtocolTest, ProtocolConstants) { 42 TEST_P(SpdyProtocolTest, ProtocolConstants) {
43 EXPECT_EQ(8u, SpdyFrame::kHeaderSize); 43 EXPECT_EQ(8u, SpdyFrame::kHeaderSize);
44 EXPECT_EQ(8u, SpdyDataFrame::size()); 44 EXPECT_EQ(8u, SpdyDataFrame::size());
45 EXPECT_EQ(8u, SpdyControlFrame::kHeaderSize); 45 EXPECT_EQ(8u, SpdyControlFrame::kHeaderSize);
46 EXPECT_EQ(18u, SpdySynStreamControlFrame::size()); 46 EXPECT_EQ(18u, SpdySynStreamControlFrame::size());
47 EXPECT_EQ(12u, SpdySynReplyControlFrame::size());
48 EXPECT_EQ(16u, SpdyRstStreamControlFrame::size()); 47 EXPECT_EQ(16u, SpdyRstStreamControlFrame::size());
49 EXPECT_EQ(12u, SpdySettingsControlFrame::size()); 48 EXPECT_EQ(12u, SpdySettingsControlFrame::size());
50 EXPECT_EQ(12u, SpdyPingControlFrame::size()); 49 EXPECT_EQ(12u, SpdyPingControlFrame::size());
51 EXPECT_EQ(12u, SpdyHeadersControlFrame::size()); 50 EXPECT_EQ(12u, SpdyHeadersControlFrame::size());
52 EXPECT_EQ(16u, SpdyWindowUpdateControlFrame::size()); 51 EXPECT_EQ(16u, SpdyWindowUpdateControlFrame::size());
53 EXPECT_EQ(4u, sizeof(FlagsAndLength)); 52 EXPECT_EQ(4u, sizeof(FlagsAndLength));
54 EXPECT_EQ(1, SYN_STREAM); 53 EXPECT_EQ(1, SYN_STREAM);
55 EXPECT_EQ(2, SYN_REPLY); 54 EXPECT_EQ(2, SYN_REPLY);
56 EXPECT_EQ(3, RST_STREAM); 55 EXPECT_EQ(3, RST_STREAM);
57 EXPECT_EQ(4, SETTINGS); 56 EXPECT_EQ(4, SETTINGS);
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 299
301 rst_frame->set_status(static_cast<SpdyRstStreamStatus>( 300 rst_frame->set_status(static_cast<SpdyRstStreamStatus>(
302 RST_STREAM_INVALID - 1)); 301 RST_STREAM_INVALID - 1));
303 EXPECT_EQ(RST_STREAM_INVALID, rst_frame->status()); 302 EXPECT_EQ(RST_STREAM_INVALID, rst_frame->status());
304 303
305 rst_frame->set_status(RST_STREAM_NUM_STATUS_CODES); 304 rst_frame->set_status(RST_STREAM_NUM_STATUS_CODES);
306 EXPECT_EQ(RST_STREAM_INVALID, rst_frame->status()); 305 EXPECT_EQ(RST_STREAM_INVALID, rst_frame->status());
307 } 306 }
308 307
309 } // namespace net 308 } // namespace net
OLDNEW
« no previous file with comments | « net/spdy/spdy_protocol.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698