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

Side by Side Diff: net/quic/quic_flow_controller_test.cc

Issue 1433433003: Rename MockHelper to the more descriptive (and more consistent with other Mock classes) MockConnect… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@106414015
Patch Set: Created 5 years, 1 month 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/quic/quic_crypto_stream_test.cc ('k') | net/quic/quic_headers_stream_test.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 #include "net/quic/quic_flow_controller.h" 5 #include "net/quic/quic_flow_controller.h"
6 6
7 #include "base/format_macros.h" 7 #include "base/format_macros.h"
8 #include "base/strings/stringprintf.h" 8 #include "base/strings/stringprintf.h"
9 #include "net/quic/quic_flags.h" 9 #include "net/quic/quic_flags.h"
10 #include "net/quic/quic_utils.h" 10 #include "net/quic/quic_utils.h"
(...skipping 22 matching lines...) Expand all
33 flow_controller_.reset( 33 flow_controller_.reset(
34 new QuicFlowController(&connection_, stream_id_, Perspective::IS_CLIENT, 34 new QuicFlowController(&connection_, stream_id_, Perspective::IS_CLIENT,
35 send_window_, receive_window_, false)); 35 send_window_, receive_window_, false));
36 } 36 }
37 37
38 protected: 38 protected:
39 QuicStreamId stream_id_; 39 QuicStreamId stream_id_;
40 QuicByteCount send_window_; 40 QuicByteCount send_window_;
41 QuicByteCount receive_window_; 41 QuicByteCount receive_window_;
42 scoped_ptr<QuicFlowController> flow_controller_; 42 scoped_ptr<QuicFlowController> flow_controller_;
43 MockHelper helper_; 43 MockConnectionHelper helper_;
44 MockConnection connection_; 44 MockConnection connection_;
45 }; 45 };
46 46
47 TEST_F(QuicFlowControllerTest, SendingBytes) { 47 TEST_F(QuicFlowControllerTest, SendingBytes) {
48 Initialize(); 48 Initialize();
49 49
50 EXPECT_FALSE(flow_controller_->IsBlocked()); 50 EXPECT_FALSE(flow_controller_->IsBlocked());
51 EXPECT_FALSE(flow_controller_->FlowControlViolation()); 51 EXPECT_FALSE(flow_controller_->FlowControlViolation());
52 EXPECT_EQ(send_window_, flow_controller_->SendWindowSize()); 52 EXPECT_EQ(send_window_, flow_controller_->SendWindowSize());
53 53
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
366 EXPECT_FALSE(flow_controller_->FlowControlViolation()); 366 EXPECT_FALSE(flow_controller_->FlowControlViolation());
367 367
368 QuicByteCount new_threshold = 368 QuicByteCount new_threshold =
369 QuicFlowControllerPeer::WindowUpdateThreshold(flow_controller_.get()); 369 QuicFlowControllerPeer::WindowUpdateThreshold(flow_controller_.get());
370 370
371 EXPECT_EQ(new_threshold, threshold); 371 EXPECT_EQ(new_threshold, threshold);
372 } 372 }
373 373
374 } // namespace test 374 } // namespace test
375 } // namespace net 375 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_crypto_stream_test.cc ('k') | net/quic/quic_headers_stream_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698