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

Unified Diff: device/bluetooth/dbus/fake_bluetooth_device_client.cc

Issue 2908673002: device/blueooth: Add BlueZ unit test for BluetoothDevice::SetConnectionInterval. (Closed)
Patch Set: test invalid case Created 3 years, 7 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
« no previous file with comments | « device/bluetooth/bluez/bluetooth_bluez_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/bluetooth/dbus/fake_bluetooth_device_client.cc
diff --git a/device/bluetooth/dbus/fake_bluetooth_device_client.cc b/device/bluetooth/dbus/fake_bluetooth_device_client.cc
index cc4eaefd168133e2254bf8b58a50028a5a22380d..4f0243de137cf02b6c0f0cf409886aea2197b029 100644
--- a/device/bluetooth/dbus/fake_bluetooth_device_client.cc
+++ b/device/bluetooth/dbus/fake_bluetooth_device_client.cc
@@ -601,8 +601,9 @@ void FakeBluetoothDeviceClient::SetLEConnectionParameters(
const base::Closure& callback,
const ErrorCallback& error_callback) {
Properties* properties = GetProperties(object_path);
- if (!properties->connected.value()) {
- error_callback.Run(bluetooth_device::kErrorNotConnected, "Not Connected");
+ if (!properties->type.is_valid() || properties->type.value() == kTypeBredr) {
+ error_callback.Run(bluetooth_device::kErrorFailed,
+ "BR/EDR devices not supported");
return;
}
« no previous file with comments | « device/bluetooth/bluez/bluetooth_bluez_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698