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

Unified Diff: device/bluetooth/test/test_bluetooth_adapter_observer.cc

Issue 1898643002: Refactor device::BluetoothGattXXX classes to split into remote/local. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 | « device/bluetooth/test/test_bluetooth_adapter_observer.h ('k') | device/device_tests.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/bluetooth/test/test_bluetooth_adapter_observer.cc
diff --git a/device/bluetooth/test/test_bluetooth_adapter_observer.cc b/device/bluetooth/test/test_bluetooth_adapter_observer.cc
index 5d62ada38e4ce4c894ca87c721e2e3f39e8986ef..5cafda3fc5aa780ba8549a9fdc866f65b314480e 100644
--- a/device/bluetooth/test/test_bluetooth_adapter_observer.cc
+++ b/device/bluetooth/test/test_bluetooth_adapter_observer.cc
@@ -8,9 +8,9 @@
#include <vector>
#include "base/message_loop/message_loop.h"
-#include "device/bluetooth/bluetooth_gatt_characteristic.h"
-#include "device/bluetooth/bluetooth_gatt_descriptor.h"
-#include "device/bluetooth/bluetooth_gatt_service.h"
+#include "device/bluetooth/bluetooth_remote_gatt_characteristic.h"
+#include "device/bluetooth/bluetooth_remote_gatt_descriptor.h"
+#include "device/bluetooth/bluetooth_remote_gatt_service.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace device {
@@ -160,7 +160,7 @@ void TestBluetoothAdapterObserver::DeviceRemoved(BluetoothAdapter* adapter,
void TestBluetoothAdapterObserver::GattServiceAdded(
BluetoothAdapter* adapter,
BluetoothDevice* device,
- BluetoothGattService* service) {
+ BluetoothRemoteGattService* service) {
ASSERT_EQ(adapter_.get(), adapter);
ASSERT_EQ(service->GetDevice(), device);
@@ -168,7 +168,6 @@ void TestBluetoothAdapterObserver::GattServiceAdded(
last_gatt_service_id_ = service->GetIdentifier();
last_gatt_service_uuid_ = service->GetUUID();
- EXPECT_FALSE(service->IsLocal());
EXPECT_TRUE(service->IsPrimary());
EXPECT_EQ(device->GetGattService(last_gatt_service_id_), service);
@@ -179,7 +178,7 @@ void TestBluetoothAdapterObserver::GattServiceAdded(
void TestBluetoothAdapterObserver::GattServiceRemoved(
BluetoothAdapter* adapter,
BluetoothDevice* device,
- BluetoothGattService* service) {
+ BluetoothRemoteGattService* service) {
ASSERT_EQ(adapter_.get(), adapter);
ASSERT_EQ(service->GetDevice(), device);
@@ -187,7 +186,6 @@ void TestBluetoothAdapterObserver::GattServiceRemoved(
last_gatt_service_id_ = service->GetIdentifier();
last_gatt_service_uuid_ = service->GetUUID();
- EXPECT_FALSE(service->IsLocal());
EXPECT_TRUE(service->IsPrimary());
// The device should return NULL for this service.
@@ -210,7 +208,7 @@ void TestBluetoothAdapterObserver::GattServicesDiscovered(
void TestBluetoothAdapterObserver::GattDiscoveryCompleteForService(
BluetoothAdapter* adapter,
- BluetoothGattService* service) {
+ BluetoothRemoteGattService* service) {
ASSERT_EQ(adapter_.get(), adapter);
++gatt_discovery_complete_count_;
@@ -219,7 +217,7 @@ void TestBluetoothAdapterObserver::GattDiscoveryCompleteForService(
void TestBluetoothAdapterObserver::GattServiceChanged(
BluetoothAdapter* adapter,
- BluetoothGattService* service) {
+ BluetoothRemoteGattService* service) {
ASSERT_EQ(adapter_.get(), adapter);
++gatt_service_changed_count_;
@@ -228,7 +226,7 @@ void TestBluetoothAdapterObserver::GattServiceChanged(
void TestBluetoothAdapterObserver::GattCharacteristicAdded(
BluetoothAdapter* adapter,
- BluetoothGattCharacteristic* characteristic) {
+ BluetoothRemoteGattCharacteristic* characteristic) {
ASSERT_EQ(adapter_.get(), adapter);
++gatt_characteristic_added_count_;
@@ -245,7 +243,7 @@ void TestBluetoothAdapterObserver::GattCharacteristicAdded(
void TestBluetoothAdapterObserver::GattCharacteristicRemoved(
BluetoothAdapter* adapter,
- BluetoothGattCharacteristic* characteristic) {
+ BluetoothRemoteGattCharacteristic* characteristic) {
ASSERT_EQ(adapter_.get(), adapter);
++gatt_characteristic_removed_count_;
@@ -262,7 +260,7 @@ void TestBluetoothAdapterObserver::GattCharacteristicRemoved(
void TestBluetoothAdapterObserver::GattDescriptorAdded(
BluetoothAdapter* adapter,
- BluetoothGattDescriptor* descriptor) {
+ BluetoothRemoteGattDescriptor* descriptor) {
ASSERT_EQ(adapter_.get(), adapter);
++gatt_descriptor_added_count_;
@@ -279,7 +277,7 @@ void TestBluetoothAdapterObserver::GattDescriptorAdded(
void TestBluetoothAdapterObserver::GattDescriptorRemoved(
BluetoothAdapter* adapter,
- BluetoothGattDescriptor* descriptor) {
+ BluetoothRemoteGattDescriptor* descriptor) {
ASSERT_EQ(adapter_.get(), adapter);
++gatt_descriptor_removed_count_;
@@ -296,7 +294,7 @@ void TestBluetoothAdapterObserver::GattDescriptorRemoved(
void TestBluetoothAdapterObserver::GattCharacteristicValueChanged(
BluetoothAdapter* adapter,
- BluetoothGattCharacteristic* characteristic,
+ BluetoothRemoteGattCharacteristic* characteristic,
const std::vector<uint8_t>& value) {
ASSERT_EQ(adapter_.get(), adapter);
@@ -315,7 +313,7 @@ void TestBluetoothAdapterObserver::GattCharacteristicValueChanged(
void TestBluetoothAdapterObserver::GattDescriptorValueChanged(
BluetoothAdapter* adapter,
- BluetoothGattDescriptor* descriptor,
+ BluetoothRemoteGattDescriptor* descriptor,
const std::vector<uint8_t>& value) {
ASSERT_EQ(adapter_.get(), adapter);
« no previous file with comments | « device/bluetooth/test/test_bluetooth_adapter_observer.h ('k') | device/device_tests.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698