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

Unified Diff: device/bluetooth/test/bluetooth_test_mac.h

Issue 1538173003: Implementing GATT connection/disconnect on OS X. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sorting methods between bluetooth_adapter_mac.h and bluetooth_adapter_mac.mm Created 4 years, 10 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: device/bluetooth/test/bluetooth_test_mac.h
diff --git a/device/bluetooth/test/bluetooth_test_mac.h b/device/bluetooth/test/bluetooth_test_mac.h
index fd354dab315bd69eaa0a502e3f2209ba4bbd3101..95d06bb897a86f414d1a12ac1ad72c5c9aaa2aa0 100644
--- a/device/bluetooth/test/bluetooth_test_mac.h
+++ b/device/bluetooth/test/bluetooth_test_mac.h
@@ -30,12 +30,22 @@ class BluetoothTestMac : public BluetoothTestBase {
void InitWithoutDefaultAdapter() override;
void InitWithFakeAdapter() override;
BluetoothDevice* DiscoverLowEnergyDevice(int device_ordinal) override;
+ void SimulateGattConnection(BluetoothDevice* device) override;
+ void SimulateGattDisconnection(BluetoothDevice* device) override;
+ void SimulateGattConnectionError(
+ BluetoothDevice* device,
+ BluetoothDevice::ConnectErrorCode errorCode) override;
+
+ // Callback for the bluetooth central manager mock.
+ void OnFakeBluetoothDeviceConnectGattCalled();
+ void OnFakeBluetoothGattDisconnect();
protected:
// Utility function for finding CBUUIDs with relatively nice SHA256 hashes.
std::string FindCBUUIDForHashTarget();
BluetoothAdapterMac* adapter_mac_ = NULL;
+ void* mock_central_manager_ = NULL;
scheib 2016/02/10 18:59:46 Could we use a scoped object from src/base/mac/ he
jlebel 2016/02/10 21:20:08 I can't include "base/mac/scoped_nsobject.h" becau
scheib 2016/03/01 17:38:17 Use #if defined(OS_MACOSX) to guard the include as
jlebel 2016/03/01 21:44:44 The issue is not OS X vs other platform. The issue
};
// Defines common test fixture name. Use TEST_F(BluetoothTest, YourTestName).

Powered by Google App Engine
This is Rietveld 408576698