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

Side by Side Diff: net/tools/quic/quic_server_session_test.cc

Issue 851503003: Update from https://crrev.com/311076 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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 | « net/tools/quic/quic_server.cc ('k') | net/tools/quic/quic_spdy_client_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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/tools/quic/quic_server_session.h" 5 #include "net/tools/quic/quic_server_session.h"
6 6
7 #include "net/quic/crypto/cached_network_parameters.h" 7 #include "net/quic/crypto/cached_network_parameters.h"
8 #include "net/quic/crypto/quic_crypto_server_config.h" 8 #include "net/quic/crypto/quic_crypto_server_config.h"
9 #include "net/quic/crypto/quic_random.h" 9 #include "net/quic/crypto/quic_random.h"
10 #include "net/quic/quic_connection.h" 10 #include "net/quic/quic_connection.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 64
65 const size_t kMaxStreamsForTest = 10; 65 const size_t kMaxStreamsForTest = 10;
66 66
67 class QuicServerSessionTest : public ::testing::TestWithParam<QuicVersion> { 67 class QuicServerSessionTest : public ::testing::TestWithParam<QuicVersion> {
68 protected: 68 protected:
69 QuicServerSessionTest() 69 QuicServerSessionTest()
70 : crypto_config_(QuicCryptoServerConfig::TESTING, 70 : crypto_config_(QuicCryptoServerConfig::TESTING,
71 QuicRandom::GetInstance()) { 71 QuicRandom::GetInstance()) {
72 config_.SetMaxStreamsPerConnection(kMaxStreamsForTest, 72 config_.SetMaxStreamsPerConnection(kMaxStreamsForTest,
73 kMaxStreamsForTest); 73 kMaxStreamsForTest);
74 config_.SetInitialFlowControlWindowToSend(
75 kInitialSessionFlowControlWindowForTest);
76 config_.SetInitialStreamFlowControlWindowToSend( 74 config_.SetInitialStreamFlowControlWindowToSend(
77 kInitialStreamFlowControlWindowForTest); 75 kInitialStreamFlowControlWindowForTest);
78 config_.SetInitialSessionFlowControlWindowToSend( 76 config_.SetInitialSessionFlowControlWindowToSend(
79 kInitialSessionFlowControlWindowForTest); 77 kInitialSessionFlowControlWindowForTest);
80 78
81 connection_ = 79 connection_ =
82 new StrictMock<MockConnection>(true, SupportedVersions(GetParam())); 80 new StrictMock<MockConnection>(true, SupportedVersions(GetParam()));
83 session_.reset(new QuicServerSession(config_, connection_, &owner_)); 81 session_.reset(new QuicServerSession(config_, connection_, &owner_));
84 MockClock clock; 82 MockClock clock;
85 handshake_message_.reset(crypto_config_.AddDefaultConfig( 83 handshake_message_.reset(crypto_config_.AddDefaultConfig(
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
429 cached_network_params.set_serving_region(kTestServingRegion); 427 cached_network_params.set_serving_region(kTestServingRegion);
430 crypto_stream->set_previous_cached_network_params(cached_network_params); 428 crypto_stream->set_previous_cached_network_params(cached_network_params);
431 EXPECT_CALL(*connection_, ResumeConnectionState(_)).Times(1); 429 EXPECT_CALL(*connection_, ResumeConnectionState(_)).Times(1);
432 session_->OnConfigNegotiated(); 430 session_->OnConfigNegotiated();
433 } 431 }
434 432
435 } // namespace 433 } // namespace
436 } // namespace test 434 } // namespace test
437 } // namespace tools 435 } // namespace tools
438 } // namespace net 436 } // namespace net
OLDNEW
« no previous file with comments | « net/tools/quic/quic_server.cc ('k') | net/tools/quic/quic_spdy_client_stream_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698