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

Side by Side Diff: net/spdy/mock_spdy_framer_visitor.h

Issue 2414293002: Deprecates --spdy_framer_use_new_methods4. (Closed)
Patch Set: Created 4 years, 2 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 | « no previous file | net/spdy/mock_spdy_framer_visitor.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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef NET_SPDY_MOCK_SPDY_FRAMER_VISITOR_H_ 5 #ifndef NET_SPDY_MOCK_SPDY_FRAMER_VISITOR_H_
6 #define NET_SPDY_MOCK_SPDY_FRAMER_VISITOR_H_ 6 #define NET_SPDY_MOCK_SPDY_FRAMER_VISITOR_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
11 #include <memory>
12
11 #include "base/strings/string_piece.h" 13 #include "base/strings/string_piece.h"
12 #include "net/spdy/spdy_framer.h" 14 #include "net/spdy/spdy_framer.h"
13 #include "net/spdy/spdy_test_utils.h" 15 #include "net/spdy/spdy_test_utils.h"
14 #include "testing/gmock/include/gmock/gmock.h" 16 #include "testing/gmock/include/gmock/gmock.h"
15 17
16 namespace net { 18 namespace net {
17 19
18 namespace test { 20 namespace test {
19 21
20 class MockSpdyFramerVisitor : public SpdyFramerVisitorInterface { 22 class MockSpdyFramerVisitor : public SpdyFramerVisitorInterface {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 base::StringPiece origin, 73 base::StringPiece origin,
72 const SpdyAltSvcWireFormat::AlternativeServiceVector& 74 const SpdyAltSvcWireFormat::AlternativeServiceVector&
73 altsvc_vector)); 75 altsvc_vector));
74 MOCK_METHOD4(OnPriority, 76 MOCK_METHOD4(OnPriority,
75 void(SpdyStreamId stream_id, 77 void(SpdyStreamId stream_id,
76 SpdyStreamId parent_stream_id, 78 SpdyStreamId parent_stream_id,
77 int weight, 79 int weight,
78 bool exclusive)); 80 bool exclusive));
79 MOCK_METHOD2(OnUnknownFrame, bool(SpdyStreamId stream_id, int frame_type)); 81 MOCK_METHOD2(OnUnknownFrame, bool(SpdyStreamId stream_id, int frame_type));
80 82
81 void DelegateNewHeaderHandling() { 83 void DelegateHeaderHandling() {
82 ON_CALL(*this, OnHeaderFrameStart(testing::_)) 84 ON_CALL(*this, OnHeaderFrameStart(testing::_))
83 .WillByDefault(testing::Invoke( 85 .WillByDefault(testing::Invoke(
84 this, &MockSpdyFramerVisitor::ReturnTestHeadersHandler)); 86 this, &MockSpdyFramerVisitor::ReturnTestHeadersHandler));
85 ON_CALL(*this, OnHeaderFrameEnd(testing::_, testing::_)) 87 ON_CALL(*this, OnHeaderFrameEnd(testing::_, testing::_))
86 .WillByDefault(testing::Invoke( 88 .WillByDefault(testing::Invoke(
87 this, &MockSpdyFramerVisitor::ResetTestHeadersHandler)); 89 this, &MockSpdyFramerVisitor::ResetTestHeadersHandler));
88 } 90 }
89 91
90 SpdyHeadersHandlerInterface* ReturnTestHeadersHandler( 92 SpdyHeadersHandlerInterface* ReturnTestHeadersHandler(
91 SpdyStreamId /* stream_id */) { 93 SpdyStreamId /* stream_id */) {
(...skipping 10 matching lines...) Expand all
102 } 104 }
103 105
104 std::unique_ptr<SpdyHeadersHandlerInterface> headers_handler_; 106 std::unique_ptr<SpdyHeadersHandlerInterface> headers_handler_;
105 }; 107 };
106 108
107 } // namespace test 109 } // namespace test
108 110
109 } // namespace net 111 } // namespace net
110 112
111 #endif // NET_SPDY_MOCK_SPDY_FRAMER_VISITOR_H_ 113 #endif // NET_SPDY_MOCK_SPDY_FRAMER_VISITOR_H_
OLDNEW
« no previous file with comments | « no previous file | net/spdy/mock_spdy_framer_visitor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698