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

Unified Diff: device/bluetooth/bluetooth_gatt_chromeos_unittest.cc

Issue 1287753002: bluetooth: Remove callback from BluetoothGattConnection::Disconnect (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge TOT Created 5 years, 3 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: device/bluetooth/bluetooth_gatt_chromeos_unittest.cc
diff --git a/device/bluetooth/bluetooth_gatt_chromeos_unittest.cc b/device/bluetooth/bluetooth_gatt_chromeos_unittest.cc
index 3c34663eee111a3f6f1da6f79d82c0f623f150b3..c81acea20d6dc823a3c8d1a5fba0df54d0680b3b 100644
--- a/device/bluetooth/bluetooth_gatt_chromeos_unittest.cc
+++ b/device/bluetooth/bluetooth_gatt_chromeos_unittest.cc
@@ -216,11 +216,7 @@ TEST_F(BluetoothGattChromeOSTest, GattConnection) {
EXPECT_EQ(FakeBluetoothDeviceClient::kLowEnergyAddress,
gatt_conn_->GetDeviceAddress());
- gatt_conn_->Disconnect(
- base::Bind(&BluetoothGattChromeOSTest::SuccessCallback,
- base::Unretained(this)));
- EXPECT_EQ(2, success_callback_count_);
- EXPECT_EQ(0, error_callback_count_);
+ gatt_conn_->Disconnect();
EXPECT_TRUE(device->IsConnected());
EXPECT_FALSE(gatt_conn_->IsConnected());
@@ -230,7 +226,7 @@ TEST_F(BluetoothGattChromeOSTest, GattConnection) {
base::Bind(&BluetoothGattChromeOSTest::ConnectErrorCallback,
base::Unretained(this)));
- EXPECT_EQ(3, success_callback_count_);
+ EXPECT_EQ(2, success_callback_count_);
EXPECT_EQ(0, error_callback_count_);
EXPECT_TRUE(device->IsConnected());
ASSERT_TRUE(gatt_conn_.get());
@@ -242,7 +238,7 @@ TEST_F(BluetoothGattChromeOSTest, GattConnection) {
base::Bind(&BluetoothGattChromeOSTest::ErrorCallback,
base::Unretained(this)));
- EXPECT_EQ(4, success_callback_count_);
+ EXPECT_EQ(3, success_callback_count_);
EXPECT_EQ(0, error_callback_count_);
ASSERT_TRUE(gatt_conn_.get());
EXPECT_FALSE(gatt_conn_->IsConnected());
@@ -253,7 +249,7 @@ TEST_F(BluetoothGattChromeOSTest, GattConnection) {
base::Bind(&BluetoothGattChromeOSTest::ConnectErrorCallback,
base::Unretained(this)));
- EXPECT_EQ(5, success_callback_count_);
+ EXPECT_EQ(4, success_callback_count_);
EXPECT_EQ(0, error_callback_count_);
EXPECT_TRUE(device->IsConnected());
EXPECT_TRUE(gatt_conn_->IsConnected());

Powered by Google App Engine
This is Rietveld 408576698