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

Unified Diff: net/quic/quic_session_test.cc

Issue 114933003: Minor cleanup of QUIC MockConnection and PacketSavingConnection (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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_reliable_client_stream_test.cc ('k') | net/quic/quic_stream_sequencer_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_session_test.cc
diff --git a/net/quic/quic_session_test.cc b/net/quic/quic_session_test.cc
index f0d4e5cc46fd91751df5f574523ce1671dee1f58..6523a3552fbbdc4ca519d478d9ac12484a917ebd 100644
--- a/net/quic/quic_session_test.cc
+++ b/net/quic/quic_session_test.cc
@@ -123,8 +123,7 @@ class TestSession : public QuicSession {
class QuicSessionTest : public ::testing::Test {
protected:
QuicSessionTest()
- : guid_(1),
- connection_(new MockConnection(guid_, IPEndPoint(), false)),
+ : connection_(new MockConnection(false)),
session_(connection_, true) {
headers_[":host"] = "www.google.com";
headers_[":path"] = "/index.hml";
@@ -170,7 +169,6 @@ class QuicSessionTest : public ::testing::Test {
closed_streams_.insert(id);
}
- QuicGuid guid_;
MockConnection* connection_;
TestSession session_;
set<QuicStreamId> closed_streams_;
@@ -178,7 +176,7 @@ class QuicSessionTest : public ::testing::Test {
};
TEST_F(QuicSessionTest, PeerAddress) {
- EXPECT_EQ(IPEndPoint(), session_.peer_address());
+ EXPECT_EQ(IPEndPoint(Loopback4(), kTestPort), session_.peer_address());
}
TEST_F(QuicSessionTest, IsCryptoHandshakeConfirmed) {
@@ -395,7 +393,7 @@ TEST_F(QuicSessionTest, IncreasedTimeoutAfterCryptoHandshake) {
TEST_F(QuicSessionTest, ZombieStream) {
StrictMock<MockConnection>* connection =
- new StrictMock<MockConnection>(guid_, IPEndPoint(), false);
+ new StrictMock<MockConnection>(false);
TestSession session(connection, /*is_server=*/ false);
TestStream* stream3 = session.CreateOutgoingDataStream();
@@ -435,7 +433,7 @@ TEST_F(QuicSessionTest, ZombieStream) {
TEST_F(QuicSessionTest, ZombieStreamConnectionClose) {
StrictMock<MockConnection>* connection =
- new StrictMock<MockConnection>(guid_, IPEndPoint(), false);
+ new StrictMock<MockConnection>(false);
TestSession session(connection, /*is_server=*/ false);
TestStream* stream3 = session.CreateOutgoingDataStream();
« no previous file with comments | « net/quic/quic_reliable_client_stream_test.cc ('k') | net/quic/quic_stream_sequencer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698