Index: device/bluetooth/test/mock_bluetooth_gatt_characteristic.h |
diff --git a/device/bluetooth/test/mock_bluetooth_gatt_characteristic.h b/device/bluetooth/test/mock_bluetooth_gatt_characteristic.h |
index 021cc599bdc42861c9ccad9f5ca812fafb0f673e..cbf0e96d4f468f76b14daa6ed82dc8b165f5de44 100644 |
--- a/device/bluetooth/test/mock_bluetooth_gatt_characteristic.h |
+++ b/device/bluetooth/test/mock_bluetooth_gatt_characteristic.h |
@@ -12,7 +12,9 @@ |
#include "base/callback.h" |
#include "base/macros.h" |
+#include "base/memory/scoped_vector.h" |
#include "device/bluetooth/bluetooth_remote_gatt_characteristic.h" |
+#include "device/bluetooth/bluetooth_remote_gatt_descriptor.h" |
#include "device/bluetooth/bluetooth_uuid.h" |
#include "testing/gmock/include/gmock/gmock.h" |
@@ -20,6 +22,7 @@ namespace device { |
class BluetoothRemoteGattDescriptor; |
class BluetoothRemoteGattService; |
+class MockBluetoothGattDescriptor; |
class MockBluetoothGattService; |
class MockBluetoothGattCharacteristic |
@@ -58,6 +61,13 @@ class MockBluetoothGattCharacteristic |
const base::Closure&, |
const ErrorCallback&)); |
+ // Also see mock_bluetooth_gatt_service |
ortuno
2016/11/21 03:34:08
Copy the comment in mock_bluetooth_gatt_service :p
dougt
2016/11/22 01:47:16
Acknowledged.
|
+ void AddMockDescriptor( |
+ std::unique_ptr<MockBluetoothGattDescriptor> mock_descriptor); |
+ std::vector<BluetoothRemoteGattDescriptor*> GetMockDescriptors() const; |
+ BluetoothRemoteGattDescriptor* GetMockDescriptor( |
+ const std::string& identifier) const; |
+ |
protected: |
MOCK_METHOD3(SubscribeToNotifications, |
void(BluetoothRemoteGattDescriptor*, |
@@ -69,6 +79,8 @@ class MockBluetoothGattCharacteristic |
const ErrorCallback&)); |
private: |
+ ScopedVector<MockBluetoothGattDescriptor> mock_descriptors_; |
ortuno
2016/11/21 03:34:08
ScopedVector is deprecated, use std::vector<std::u
dougt
2016/11/22 01:47:16
Acknowledged.
|
+ |
DISALLOW_COPY_AND_ASSIGN(MockBluetoothGattCharacteristic); |
}; |