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

Unified Diff: content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.cc

Issue 1217983004: bluetooth: browser-side implementation of writeValue. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bluetooth-origin
Patch Set: Remove comment Created 5 years, 5 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: content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.cc
diff --git a/content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.cc b/content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.cc
index 4c0635a49a7148ea35fae36a3b613ececd4434bb..aad6fe5f25b66b485fecd18dd64f7a7537ff2367 100644
--- a/content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.cc
+++ b/content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.cc
@@ -272,6 +272,10 @@ LayoutTestBluetoothAdapterProvider::GetEmptyDevice(
ON_CALL(*device_name_characteristic, ReadRemoteCharacteristic(_, _))
.WillByDefault(RunCallback<0>(device_name_value));
+ ON_CALL(*device_name_characteristic, WriteRemoteCharacteristic(_, _, _))
+ .WillByDefault(RunCallback<2 /* error callback */>(
+ BluetoothGattService::GATT_ERROR_NOT_PERMITTED));
+
generic_access->AddMockCharacteristic(device_name_characteristic.Pass());
scoped_ptr<NiceMock<MockBluetoothGattCharacteristic>> reconnection_address(
@@ -282,6 +286,9 @@ LayoutTestBluetoothAdapterProvider::GetEmptyDevice(
.WillByDefault(
RunCallback<1>(BluetoothGattService::GATT_ERROR_NOT_PERMITTED));
+ ON_CALL(*reconnection_address, WriteRemoteCharacteristic(_, _, _))
+ .WillByDefault(RunCallback<1 /* success callback */>());
+
generic_access->AddMockCharacteristic(reconnection_address.Pass());
empty_device->AddMockService(generic_access.Pass());
« no previous file with comments | « content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698