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

Unified Diff: components/proximity_auth/ble/bluetooth_low_energy_connection_finder_unittest.cc

Issue 2196883002: bluetooth: Add optional 'name' support to MockBluetoothDevice. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 | « no previous file | content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/proximity_auth/ble/bluetooth_low_energy_connection_finder_unittest.cc
diff --git a/components/proximity_auth/ble/bluetooth_low_energy_connection_finder_unittest.cc b/components/proximity_auth/ble/bluetooth_low_energy_connection_finder_unittest.cc
index be22b1852b8531f3611b1ca5e15e250467d64a3a..ec7cca152601c31007d934a6cfd0b06580355531 100644
--- a/components/proximity_auth/ble/bluetooth_low_energy_connection_finder_unittest.cc
+++ b/components/proximity_auth/ble/bluetooth_low_energy_connection_finder_unittest.cc
@@ -257,8 +257,8 @@ TEST_F(ProximityAuthBluetoothLowEnergyConnectionFinderTest,
ExpectRemoveObserver();
PrepareDevice(kServiceUUID, kTestRemoteDeviceBluetoothAddress, false);
- ON_CALL(*device_, GetNameForDisplay())
- .WillByDefault(Return(base::UTF8ToUTF16(kTestRemoteDeviceName)));
+ ON_CALL(*device_, GetName())
+ .WillByDefault(Return(std::string(kTestRemoteDeviceName)));
connection_finder.ExpectCreateConnection();
connection_finder.DeviceAdded(adapter_.get(), device_.get());
@@ -273,8 +273,7 @@ TEST_F(ProximityAuthBluetoothLowEnergyConnectionFinderTest,
ExpectRemoveObserver();
PrepareDevice(kOtherUUID, kTestRemoteDeviceBluetoothAddress, false);
- ON_CALL(*device_, GetNameForDisplay())
- .WillByDefault(Return(base::UTF8ToUTF16("Other name")));
+ ON_CALL(*device_, GetName()).WillByDefault(Return(std::string("Other name")));
EXPECT_CALL(connection_finder, CreateConnectionProxy()).Times(0);
connection_finder.DeviceAdded(adapter_.get(), device_.get());
« no previous file with comments | « no previous file | content/shell/browser/layout_test/layout_test_bluetooth_adapter_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698