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

Unified Diff: net/tools/quic/test_tools/quic_test_utils.cc

Issue 1029463003: Improve tests. Correct things clang_tidy complains about. Make (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/tools/quic/test_tools/quic_test_utils.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/tools/quic/test_tools/quic_test_utils.cc
diff --git a/net/tools/quic/test_tools/quic_test_utils.cc b/net/tools/quic/test_tools/quic_test_utils.cc
index 6a5e93c8e593a2237ede843a94e270a5d6403f13..b2420b41f6d41636988e9e029116dc2cfbfe2eb2 100644
--- a/net/tools/quic/test_tools/quic_test_utils.cc
+++ b/net/tools/quic/test_tools/quic_test_utils.cc
@@ -14,6 +14,9 @@ using base::StringPiece;
using net::test::MakeAckFrame;
using net::test::MockHelper;
using net::test::QuicConnectionPeer;
+using testing::_;
+using testing::AnyNumber;
+using testing::Invoke;
namespace net {
namespace tools {
@@ -117,6 +120,13 @@ MockTimeWaitListManager::MockTimeWaitListManager(
QuicServerSessionVisitor* visitor,
EpollServer* eps)
: QuicTimeWaitListManager(writer, visitor, eps, QuicSupportedVersions()) {
+ // Though AddConnectionIdToTimeWait is mocked, we want to retain its
+ // functionality.
+ EXPECT_CALL(*this, AddConnectionIdToTimeWait(_, _, _)).Times(AnyNumber());
+ ON_CALL(*this, AddConnectionIdToTimeWait(_, _, _))
+ .WillByDefault(
+ Invoke(this, &MockTimeWaitListManager::
+ QuicTimeWaitListManager_AddConnectionIdToTimeWait));
}
MockTimeWaitListManager::~MockTimeWaitListManager() {
« no previous file with comments | « net/tools/quic/test_tools/quic_test_utils.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698