| OLD | NEW |
| 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_simple_server_session.h" | 5 #include "net/tools/quic/quic_simple_server_session.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 199 QuicRandom::GetInstance(), &clock, | 199 QuicRandom::GetInstance(), &clock, |
| 200 QuicCryptoServerConfig::ConfigOptions())); | 200 QuicCryptoServerConfig::ConfigOptions())); |
| 201 session_->Initialize(); | 201 session_->Initialize(); |
| 202 visitor_ = QuicConnectionPeer::GetVisitor(connection_); | 202 visitor_ = QuicConnectionPeer::GetVisitor(connection_); |
| 203 headers_stream_ = new MockQuicHeadersStream(session_.get()); | 203 headers_stream_ = new MockQuicHeadersStream(session_.get()); |
| 204 QuicSpdySessionPeer::SetHeadersStream(session_.get(), headers_stream_); | 204 QuicSpdySessionPeer::SetHeadersStream(session_.get(), headers_stream_); |
| 205 | 205 |
| 206 session_->OnConfigNegotiated(); | 206 session_->OnConfigNegotiated(); |
| 207 } | 207 } |
| 208 | 208 |
| 209 QuicFlagSaver flags_; // Save/restore all QUIC flag values. |
| 209 StrictMock<MockQuicServerSessionVisitor> owner_; | 210 StrictMock<MockQuicServerSessionVisitor> owner_; |
| 210 StrictMock<MockQuicServerSessionHelper> session_helper_; | 211 StrictMock<MockQuicServerSessionHelper> session_helper_; |
| 211 MockQuicConnectionHelper helper_; | 212 MockQuicConnectionHelper helper_; |
| 212 MockAlarmFactory alarm_factory_; | 213 MockAlarmFactory alarm_factory_; |
| 213 StrictMock<MockQuicConnectionWithSendStreamData>* connection_; | 214 StrictMock<MockQuicConnectionWithSendStreamData>* connection_; |
| 214 QuicConfig config_; | 215 QuicConfig config_; |
| 215 QuicCryptoServerConfig crypto_config_; | 216 QuicCryptoServerConfig crypto_config_; |
| 216 QuicCompressedCertsCache compressed_certs_cache_; | 217 QuicCompressedCertsCache compressed_certs_cache_; |
| 217 std::unique_ptr<QuicSimpleServerSession> session_; | 218 std::unique_ptr<QuicSimpleServerSession> session_; |
| 218 std::unique_ptr<CryptoHandshakeMessage> handshake_message_; | 219 std::unique_ptr<CryptoHandshakeMessage> handshake_message_; |
| (...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 619 .WillOnce(Return(QuicConsumedData(kStreamFlowControlWindowSize, false))); | 620 .WillOnce(Return(QuicConsumedData(kStreamFlowControlWindowSize, false))); |
| 620 | 621 |
| 621 EXPECT_CALL(*connection_, SendBlocked(stream_to_open)); | 622 EXPECT_CALL(*connection_, SendBlocked(stream_to_open)); |
| 622 QuicRstStreamFrame rst(stream_got_reset, QUIC_STREAM_CANCELLED, 0); | 623 QuicRstStreamFrame rst(stream_got_reset, QUIC_STREAM_CANCELLED, 0); |
| 623 visitor_->OnRstStream(rst); | 624 visitor_->OnRstStream(rst); |
| 624 } | 625 } |
| 625 | 626 |
| 626 } // namespace | 627 } // namespace |
| 627 } // namespace test | 628 } // namespace test |
| 628 } // namespace net | 629 } // namespace net |
| OLD | NEW |