Index: device/bluetooth/test/mock_bluetooth_adapter.cc |
diff --git a/device/bluetooth/test/mock_bluetooth_adapter.cc b/device/bluetooth/test/mock_bluetooth_adapter.cc |
index 4b47579fb1f4fa4eefb49b598f3636ffbc395498..1532ccb92f4c3ac0ba054d0bd429eafd7d846e65 100644 |
--- a/device/bluetooth/test/mock_bluetooth_adapter.cc |
+++ b/device/bluetooth/test/mock_bluetooth_adapter.cc |
@@ -46,6 +46,27 @@ void MockBluetoothAdapter::StartDiscoverySessionWithFilter( |
error_callback); |
} |
+void MockBluetoothAdapter::AddMockDevice( |
+ scoped_ptr<MockBluetoothDevice> mock_device) { |
+ mock_devices_.push_back(mock_device.Pass()); |
+} |
+ |
+BluetoothAdapter::ConstDeviceList MockBluetoothAdapter::GetConstMockDevices() { |
+ BluetoothAdapter::ConstDeviceList devices; |
+ for (auto& it : mock_devices_) { |
+ devices.push_back(it); |
+ } |
+ return devices; |
+} |
+ |
+BluetoothAdapter::DeviceList MockBluetoothAdapter::GetMockDevices() { |
+ BluetoothAdapter::DeviceList devices; |
+ for (auto& it : mock_devices_) { |
+ devices.push_back(it); |
+ } |
+ return devices; |
+} |
+ |
void MockBluetoothAdapter::RegisterAdvertisement( |
scoped_ptr<BluetoothAdvertisement::Data> advertisement_data, |
const CreateAdvertisementCallback& callback, |