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

Unified Diff: net/quic/quic_http_stream_test.cc

Issue 1825423003: Use scoped_ptr for MockUDPClientSocket in quic_http_stream_test.cc and bidirectional_stream_quic_im… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@log
Patch Set: Created 4 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/quic/bidirectional_stream_quic_impl_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_http_stream_test.cc
diff --git a/net/quic/quic_http_stream_test.cc b/net/quic/quic_http_stream_test.cc
index cafeb0cd128b5f3f4834c5a8463eb301228c113a..3e2c444e02d72cd8794ac2ec5e3519af0301b9f5 100644
--- a/net/quic/quic_http_stream_test.cc
+++ b/net/quic/quic_http_stream_test.cc
@@ -196,8 +196,8 @@ class QuicHttpStreamTest : public ::testing::TestWithParam<QuicVersion> {
socket_data_.reset(new StaticSocketDataProvider(
nullptr, 0, mock_writes_.get(), writes_.size()));
- MockUDPClientSocket* socket =
- new MockUDPClientSocket(socket_data_.get(), net_log_.bound().net_log());
+ scoped_ptr<MockUDPClientSocket> socket(new MockUDPClientSocket(
+ socket_data_.get(), net_log_.bound().net_log()));
socket->Connect(peer_addr_);
runner_ = new TestTaskRunner(&clock_);
send_algorithm_ = new MockSendAlgorithm();
@@ -220,7 +220,7 @@ class QuicHttpStreamTest : public ::testing::TestWithParam<QuicVersion> {
&random_generator_));
connection_ = new TestQuicConnection(
SupportedVersions(GetParam()), connection_id_, peer_addr_,
- helper_.get(), new QuicChromiumPacketWriter(socket));
+ helper_.get(), new QuicChromiumPacketWriter(socket.get()));
connection_->set_visitor(&visitor_);
connection_->SetSendAlgorithm(send_algorithm_);
@@ -234,7 +234,7 @@ class QuicHttpStreamTest : public ::testing::TestWithParam<QuicVersion> {
crypto_client_stream_factory_.AddProofVerifyDetails(&verify_details_);
session_.reset(new QuicChromiumClientSession(
- connection_, scoped_ptr<DatagramClientSocket>(socket),
+ connection_, std::move(socket),
/*stream_factory=*/nullptr, &crypto_client_stream_factory_, &clock_,
&transport_security_state_, make_scoped_ptr((QuicServerInfo*)nullptr),
QuicServerId(kDefaultServerHostName, kDefaultServerPort,
« no previous file with comments | « net/quic/bidirectional_stream_quic_impl_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698