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

Unified Diff: google_apis/gcm/engine/connection_handler_impl_unittest.cc

Issue 1873663002: Convert //google_apis from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
Index: google_apis/gcm/engine/connection_handler_impl_unittest.cc
diff --git a/google_apis/gcm/engine/connection_handler_impl_unittest.cc b/google_apis/gcm/engine/connection_handler_impl_unittest.cc
index 31f39fe8c18ca4b4704620f07fa1d0d468e6cbff..9ca9c6483ea346525bb2f1ca91d49398aebabf7c 100644
--- a/google_apis/gcm/engine/connection_handler_impl_unittest.cc
+++ b/google_apis/gcm/engine/connection_handler_impl_unittest.cc
@@ -5,11 +5,12 @@
#include "google_apis/gcm/engine/connection_handler_impl.h"
#include <stdint.h>
+
+#include <memory>
#include <string>
#include <utility>
#include "base/bind.h"
-#include "base/memory/scoped_ptr.h"
#include "base/run_loop.h"
#include "base/strings/string_number_conversions.h"
#include "base/test/test_timeouts.h"
@@ -27,7 +28,7 @@
namespace gcm {
namespace {
-typedef scoped_ptr<google::protobuf::MessageLite> ScopedMessage;
+typedef std::unique_ptr<google::protobuf::MessageLite> ScopedMessage;
typedef std::vector<net::MockRead> ReadList;
typedef std::vector<net::MockWrite> WriteList;
@@ -171,21 +172,21 @@ class GCMConnectionHandlerImplTest : public testing::Test {
// SocketStreams and their data provider.
ReadList mock_reads_;
WriteList mock_writes_;
- scoped_ptr<net::StaticSocketDataProvider> data_provider_;
+ std::unique_ptr<net::StaticSocketDataProvider> data_provider_;
// The connection handler being tested.
- scoped_ptr<ConnectionHandlerImpl> connection_handler_;
+ std::unique_ptr<ConnectionHandlerImpl> connection_handler_;
// The last connection error received.
int last_error_;
// net:: components.
- scoped_ptr<net::StreamSocket> socket_;
+ std::unique_ptr<net::StreamSocket> socket_;
net::MockClientSocketFactory socket_factory_;
net::AddressList address_list_;
base::MessageLoopForIO message_loop_;
- scoped_ptr<base::RunLoop> run_loop_;
+ std::unique_ptr<base::RunLoop> run_loop_;
};
GCMConnectionHandlerImplTest::GCMConnectionHandlerImplTest()

Powered by Google App Engine
This is Rietveld 408576698