OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/quic/quic_http_stream.h" | 5 #include "net/quic/quic_http_stream.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "net/base/net_errors.h" | 9 #include "net/base/net_errors.h" |
10 #include "net/base/test_completion_callback.h" | 10 #include "net/base/test_completion_callback.h" |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 session_.reset( | 207 session_.reset( |
208 new QuicClientSession(connection_, | 208 new QuicClientSession(connection_, |
209 scoped_ptr<DatagramClientSocket>(socket), | 209 scoped_ptr<DatagramClientSocket>(socket), |
210 writer_.Pass(), NULL, | 210 writer_.Pass(), NULL, |
211 &crypto_client_stream_factory_, | 211 &crypto_client_stream_factory_, |
212 make_scoped_ptr((QuicServerInfo*)NULL), | 212 make_scoped_ptr((QuicServerInfo*)NULL), |
213 QuicServerId(kServerHostname, kServerPort, | 213 QuicServerId(kServerHostname, kServerPort, |
214 false, PRIVACY_MODE_DISABLED), | 214 false, PRIVACY_MODE_DISABLED), |
215 DefaultQuicConfig(), | 215 DefaultQuicConfig(), |
216 kInitialFlowControlWindowForTest, &crypto_config_, | 216 kInitialFlowControlWindowForTest, &crypto_config_, |
| 217 |
| 218 base::MessageLoop::current()-> |
| 219 message_loop_proxy().get(), |
217 NULL)); | 220 NULL)); |
218 session_->GetCryptoStream()->CryptoConnect(); | 221 session_->GetCryptoStream()->CryptoConnect(); |
219 EXPECT_TRUE(session_->IsCryptoHandshakeConfirmed()); | 222 EXPECT_TRUE(session_->IsCryptoHandshakeConfirmed()); |
220 stream_.reset(use_closing_stream_ ? | 223 stream_.reset(use_closing_stream_ ? |
221 new AutoClosingStream(session_->GetWeakPtr()) : | 224 new AutoClosingStream(session_->GetWeakPtr()) : |
222 new QuicHttpStream(session_->GetWeakPtr())); | 225 new QuicHttpStream(session_->GetWeakPtr())); |
223 clock_.AdvanceTime(QuicTime::Delta::FromMilliseconds(20)); | 226 clock_.AdvanceTime(QuicTime::Delta::FromMilliseconds(20)); |
224 } | 227 } |
225 | 228 |
226 void SetRequest(const std::string& method, | 229 void SetRequest(const std::string& method, |
(...skipping 382 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
609 // Set Delegate to NULL and make sure EffectivePriority returns highest | 612 // Set Delegate to NULL and make sure EffectivePriority returns highest |
610 // priority. | 613 // priority. |
611 reliable_stream->SetDelegate(NULL); | 614 reliable_stream->SetDelegate(NULL); |
612 DCHECK_EQ(QuicWriteBlockedList::kHighestPriority, | 615 DCHECK_EQ(QuicWriteBlockedList::kHighestPriority, |
613 reliable_stream->EffectivePriority()); | 616 reliable_stream->EffectivePriority()); |
614 reliable_stream->SetDelegate(delegate); | 617 reliable_stream->SetDelegate(delegate); |
615 } | 618 } |
616 | 619 |
617 } // namespace test | 620 } // namespace test |
618 } // namespace net | 621 } // namespace net |
OLD | NEW |