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

Unified Diff: device/bluetooth/test/bluetooth_test.cc

Issue 2567903004: Replace ScopedVector/ScopedPtrHashMap with std::vector and std::unordered_map (Closed)
Patch Set: Mac bustage Created 4 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
Index: device/bluetooth/test/bluetooth_test.cc
diff --git a/device/bluetooth/test/bluetooth_test.cc b/device/bluetooth/test/bluetooth_test.cc
index d0208ddc7a1b3d44da43621188e7e5267dd95471..c089591922d61e1bcacd6b0d583a65542b582925 100644
--- a/device/bluetooth/test/bluetooth_test.cc
+++ b/device/bluetooth/test/bluetooth_test.cc
@@ -110,7 +110,7 @@ void BluetoothTestBase::DiscoverySessionCallback(
Call expected,
std::unique_ptr<BluetoothDiscoverySession> discovery_session) {
++callback_count_;
- discovery_sessions_.push_back(discovery_session.release());
+ discovery_sessions_.push_back(std::move(discovery_session));
if (expected == Call::EXPECTED)
++actual_success_callback_calls_;
@@ -122,7 +122,7 @@ void BluetoothTestBase::GattConnectionCallback(
Call expected,
std::unique_ptr<BluetoothGattConnection> connection) {
++callback_count_;
- gatt_connections_.push_back(connection.release());
+ gatt_connections_.push_back(std::move(connection));
if (expected == Call::EXPECTED)
++actual_success_callback_calls_;
@@ -133,7 +133,7 @@ void BluetoothTestBase::GattConnectionCallback(
void BluetoothTestBase::NotifyCallback(
Call expected,
std::unique_ptr<BluetoothGattNotifySession> notify_session) {
- notify_sessions_.push_back(notify_session.release());
+ notify_sessions_.push_back(std::move(notify_session));
++callback_count_;
if (expected == Call::EXPECTED)
@@ -147,7 +147,7 @@ void BluetoothTestBase::NotifyCheckForPrecedingCalls(
std::unique_ptr<BluetoothGattNotifySession> notify_session) {
EXPECT_EQ(num_of_preceding_calls, callback_count_);
- notify_sessions_.push_back(notify_session.release());
+ notify_sessions_.push_back(std::move(notify_session));
++callback_count_;
++actual_success_callback_calls_;

Powered by Google App Engine
This is Rietveld 408576698