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

Unified Diff: net/quic/quic_flow_controller_test.cc

Issue 761903003: Update from https://crrev.com/306655 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_flow_controller.cc ('k') | net/quic/quic_framer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_flow_controller_test.cc
diff --git a/net/quic/quic_flow_controller_test.cc b/net/quic/quic_flow_controller_test.cc
index f96016953b2fa093a4388be42914eb479d7ebc0f..e3fcafea5f5f178ff3727eea48840a5aeee6ae86 100644
--- a/net/quic/quic_flow_controller_test.cc
+++ b/net/quic/quic_flow_controller_test.cc
@@ -4,6 +4,7 @@
#include "net/quic/quic_flow_controller.h"
+#include "base/format_macros.h"
#include "base/strings/stringprintf.h"
#include "net/quic/quic_utils.h"
#include "net/quic/test_tools/quic_connection_peer.h"
@@ -12,13 +13,9 @@
#include "net/test/gtest_util.h"
#include "testing/gmock/include/gmock/gmock.h"
-using base::StringPrintf;
-
namespace net {
namespace test {
-using ::testing::_;
-
class QuicFlowControllerTest : public ::testing::Test {
public:
QuicFlowControllerTest()
@@ -37,9 +34,9 @@ class QuicFlowControllerTest : public ::testing::Test {
protected:
QuicStreamId stream_id_;
- uint64 send_window_;
- uint64 receive_window_;
- uint64 max_receive_window_;
+ QuicByteCount send_window_;
+ QuicByteCount receive_window_;
+ QuicByteCount max_receive_window_;
scoped_ptr<QuicFlowController> flow_controller_;
MockConnection connection_;
};
@@ -80,8 +77,8 @@ TEST_F(QuicFlowControllerTest, SendingBytes) {
SendConnectionClose(QUIC_FLOW_CONTROL_SENT_TOO_MUCH_DATA));
EXPECT_DFATAL(
flow_controller_->AddBytesSent(send_window_ * 10),
- StringPrintf("Trying to send an extra %d bytes",
- static_cast<int>(send_window_ * 10)));
+ base::StringPrintf("Trying to send an extra %" PRIu64 " bytes",
+ send_window_ * 10));
EXPECT_TRUE(flow_controller_->IsBlocked());
EXPECT_EQ(0u, flow_controller_->SendWindowSize());
}
@@ -104,7 +101,7 @@ TEST_F(QuicFlowControllerTest, ReceivingBytes) {
QuicFlowControllerPeer::ReceiveWindowSize(flow_controller_.get()));
// Consume enough bytes to send a WINDOW_UPDATE frame.
- EXPECT_CALL(connection_, SendWindowUpdate(stream_id_, _)).Times(1);
+ EXPECT_CALL(connection_, SendWindowUpdate(stream_id_, ::testing::_)).Times(1);
flow_controller_->AddBytesConsumed(1 + receive_window_ / 2);
« no previous file with comments | « net/quic/quic_flow_controller.cc ('k') | net/quic/quic_framer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698