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

Unified Diff: chromeos/components/tether/ble_connection_manager_unittest.cc

Issue 2803153002: [CrOS Tether] Refactor BleScanner so that it takes a BluetoothAdapter in its constructor instead of… (Closed)
Patch Set: Created 3 years, 8 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 | « chromeos/components/tether/ble_connection_manager.cc ('k') | chromeos/components/tether/ble_scanner.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/components/tether/ble_connection_manager_unittest.cc
diff --git a/chromeos/components/tether/ble_connection_manager_unittest.cc b/chromeos/components/tether/ble_connection_manager_unittest.cc
index 403eb2dc564e3c4c2d5842f13453712ba4c0ad3e..fc9f4e2ae444a081cbe7c4ba64cdf1376930c821 100644
--- a/chromeos/components/tether/ble_connection_manager_unittest.cc
+++ b/chromeos/components/tether/ble_connection_manager_unittest.cc
@@ -93,7 +93,8 @@ class TestObserver : public BleConnectionManager::Observer {
class MockBleScanner : public BleScanner {
public:
- MockBleScanner() : BleScanner(nullptr) {}
+ MockBleScanner(scoped_refptr<device::BluetoothAdapter> adapter)
+ : BleScanner(adapter, nullptr) {}
~MockBleScanner() override {}
MOCK_METHOD1(RegisterScanFilterForDevice,
@@ -251,7 +252,7 @@ class BleConnectionManagerTest : public testing::Test {
mock_adapter_ =
make_scoped_refptr(new NiceMock<device::MockBluetoothAdapter>());
- mock_ble_scanner_ = new MockBleScanner();
+ mock_ble_scanner_ = new MockBleScanner(mock_adapter_);
ON_CALL(*mock_ble_scanner_, RegisterScanFilterForDevice(_))
.WillByDefault(Return(true));
ON_CALL(*mock_ble_scanner_, UnregisterScanFilterForDevice(_))
« no previous file with comments | « chromeos/components/tether/ble_connection_manager.cc ('k') | chromeos/components/tether/ble_scanner.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698