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

Unified Diff: net/http/http_network_transaction_unittest.cc

Issue 1545233002: Convert Pass()→std::move() in //net (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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/http/http_network_transaction.cc ('k') | net/http/http_proxy_client_socket_pool.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_network_transaction_unittest.cc
diff --git a/net/http/http_network_transaction_unittest.cc b/net/http/http_network_transaction_unittest.cc
index 1a1f4d8b3d2c077486cea2240d25300617c282bf..ed7470b3a618ffba8be29837496992d3e2f5ca21 100644
--- a/net/http/http_network_transaction_unittest.cc
+++ b/net/http/http_network_transaction_unittest.cc
@@ -7,9 +7,9 @@
#include <math.h> // ceil
#include <stdarg.h>
#include <stdint.h>
-
#include <limits>
#include <string>
+#include <utility>
#include <vector>
#include "base/compiler_specific.h"
@@ -3519,7 +3519,7 @@ TEST_P(HttpNetworkTransactionTest,
mock_handler->set_allows_default_credentials(true);
auth_handler_factory->AddMockHandler(mock_handler.release(),
HttpAuth::AUTH_PROXY);
- session_deps_.http_auth_handler_factory = auth_handler_factory.Pass();
+ session_deps_.http_auth_handler_factory = std::move(auth_handler_factory);
// Add NetLog just so can verify load timing information gets a NetLog ID.
NetLog net_log;
@@ -3636,7 +3636,7 @@ TEST_P(HttpNetworkTransactionTest,
mock_handler->set_allows_default_credentials(true);
auth_handler_factory->AddMockHandler(mock_handler.release(),
HttpAuth::AUTH_PROXY);
- session_deps_.http_auth_handler_factory = auth_handler_factory.Pass();
+ session_deps_.http_auth_handler_factory = std::move(auth_handler_factory);
// Add NetLog just so can verify load timing information gets a NetLog ID.
NetLog net_log;
@@ -3758,7 +3758,7 @@ TEST_P(HttpNetworkTransactionTest,
mock_handler->set_allows_default_credentials(true);
auth_handler_factory->AddMockHandler(mock_handler.release(),
HttpAuth::AUTH_PROXY);
- session_deps_.http_auth_handler_factory = auth_handler_factory.Pass();
+ session_deps_.http_auth_handler_factory = std::move(auth_handler_factory);
// Add NetLog just so can verify load timing information gets a NetLog ID.
NetLog net_log;
@@ -3862,7 +3862,7 @@ TEST_P(HttpNetworkTransactionTest,
mock_handler->set_allows_default_credentials(true);
auth_handler_factory->AddMockHandler(mock_handler.release(),
HttpAuth::AUTH_PROXY);
- session_deps_.http_auth_handler_factory = auth_handler_factory.Pass();
+ session_deps_.http_auth_handler_factory = std::move(auth_handler_factory);
// Add NetLog just so can verify load timing information gets a NetLog ID.
NetLog net_log;
@@ -8788,7 +8788,7 @@ TEST_P(HttpNetworkTransactionTest, GroupNameForDirectConnections) {
new MockClientSocketPoolManager);
mock_pool_manager->SetTransportSocketPool(transport_conn_pool);
mock_pool_manager->SetSSLSocketPool(ssl_conn_pool);
- peer.SetClientSocketPoolManager(mock_pool_manager.Pass());
+ peer.SetClientSocketPoolManager(std::move(mock_pool_manager));
EXPECT_EQ(ERR_IO_PENDING,
GroupNameTransactionHelper(tests[i].url, session.get()));
@@ -8853,7 +8853,7 @@ TEST_P(HttpNetworkTransactionTest, GroupNameForHTTPProxyConnections) {
new MockClientSocketPoolManager);
mock_pool_manager->SetSocketPoolForHTTPProxy(proxy_host, http_proxy_pool);
mock_pool_manager->SetSocketPoolForSSLWithProxy(proxy_host, ssl_conn_pool);
- peer.SetClientSocketPoolManager(mock_pool_manager.Pass());
+ peer.SetClientSocketPoolManager(std::move(mock_pool_manager));
EXPECT_EQ(ERR_IO_PENDING,
GroupNameTransactionHelper(tests[i].url, session.get()));
@@ -8923,7 +8923,7 @@ TEST_P(HttpNetworkTransactionTest, GroupNameForSOCKSConnections) {
new MockClientSocketPoolManager);
mock_pool_manager->SetSocketPoolForSOCKSProxy(proxy_host, socks_conn_pool);
mock_pool_manager->SetSocketPoolForSSLWithProxy(proxy_host, ssl_conn_pool);
- peer.SetClientSocketPoolManager(mock_pool_manager.Pass());
+ peer.SetClientSocketPoolManager(std::move(mock_pool_manager));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -11563,7 +11563,7 @@ TEST_P(HttpNetworkTransactionTest, MultiRoundAuth) {
scoped_ptr<MockClientSocketPoolManager> mock_pool_manager(
new MockClientSocketPoolManager);
mock_pool_manager->SetTransportSocketPool(transport_pool);
- session_peer.SetClientSocketPoolManager(mock_pool_manager.Pass());
+ session_peer.SetClientSocketPoolManager(std::move(mock_pool_manager));
scoped_ptr<HttpTransaction> trans(
new HttpNetworkTransaction(DEFAULT_PRIORITY, session.get()));
@@ -14681,7 +14681,7 @@ class FakeWebSocketStreamCreateHelper :
WebSocketHandshakeStreamBase* CreateBasicStream(
scoped_ptr<ClientSocketHandle> connection,
bool using_proxy) override {
- return new FakeWebSocketBasicHandshakeStream(connection.Pass(),
+ return new FakeWebSocketBasicHandshakeStream(std::move(connection),
using_proxy);
}
« no previous file with comments | « net/http/http_network_transaction.cc ('k') | net/http/http_proxy_client_socket_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698