Chromium Code Reviews| Index: device/bluetooth/bluetooth_remote_gatt_characteristic_unittest.cc |
| diff --git a/device/bluetooth/bluetooth_remote_gatt_characteristic_unittest.cc b/device/bluetooth/bluetooth_remote_gatt_characteristic_unittest.cc |
| index 37f205f6c8c8095b011244ae1b6863ad2bf7898d..f76af7fbcb9457cacb40d1b5c4b1539b535c1aff 100644 |
| --- a/device/bluetooth/bluetooth_remote_gatt_characteristic_unittest.cc |
| +++ b/device/bluetooth/bluetooth_remote_gatt_characteristic_unittest.cc |
| @@ -398,6 +398,16 @@ TEST_F(BluetoothRemoteGattCharacteristicTest, ReadRemoteCharacteristic) { |
| #endif // defined(OS_ANDROID) || defined(OS_WIN) |
| #if defined(OS_ANDROID) || defined(OS_WIN) |
| +// Callback that make sure GattCharacteristicValueChanged has been called |
| +// before the callback runs. |
| +static void test_callback( |
|
ortuno
2016/06/25 00:19:36
Since this is no longer a lambda you can remove th
pcc1
2016/06/25 00:26:39
Done.
|
| + BluetoothRemoteGattCharacteristic::ValueCallback callback, |
| + const TestBluetoothAdapterObserver& callback_observer, |
| + const std::vector<uint8_t>& value) { |
| + EXPECT_EQ(1, callback_observer.gatt_characteristic_value_changed_count()); |
| + callback.Run(value); |
| +} |
| + |
| // Tests that ReadRemoteCharacteristic results in a |
| // GattCharacteristicValueChanged call. |
| TEST_F(BluetoothRemoteGattCharacteristicTest, |
| @@ -407,16 +417,6 @@ TEST_F(BluetoothRemoteGattCharacteristicTest, |
| TestBluetoothAdapterObserver observer(adapter_); |
| - // Callback that make sure GattCharacteristicValueChanged has been called |
| - // before the callback runs. |
| - auto test_callback = []( |
| - BluetoothRemoteGattCharacteristic::ValueCallback callback, |
| - const TestBluetoothAdapterObserver& callback_observer, |
| - const std::vector<uint8_t>& value) { |
| - EXPECT_EQ(1, callback_observer.gatt_characteristic_value_changed_count()); |
| - callback.Run(value); |
| - }; |
| - |
| characteristic1_->ReadRemoteCharacteristic( |
| base::Bind((void (*)(BluetoothRemoteGattCharacteristic::ValueCallback, |
| const TestBluetoothAdapterObserver&, |