| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_SHELL_BROWSER_LAYOUT_TEST_LAYOUT_TEST_BLUETOOTH_ADAPTER_PROVIDER
_H_ | 5 #ifndef CONTENT_SHELL_BROWSER_LAYOUT_TEST_LAYOUT_TEST_BLUETOOTH_ADAPTER_PROVIDER
_H_ |
| 6 #define CONTENT_SHELL_BROWSER_LAYOUT_TEST_LAYOUT_TEST_BLUETOOTH_ADAPTER_PROVIDER
_H_ | 6 #define CONTENT_SHELL_BROWSER_LAYOUT_TEST_LAYOUT_TEST_BLUETOOTH_ADAPTER_PROVIDER
_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 348 // Returns uuids | 348 // Returns uuids |
| 349 // - GetGattServices: | 349 // - GetGattServices: |
| 350 // Returns a list of all services added to the device. | 350 // Returns a list of all services added to the device. |
| 351 // - GetGattService: | 351 // - GetGattService: |
| 352 // Return a service matching the identifier provided if the service was | 352 // Return a service matching the identifier provided if the service was |
| 353 // added to the mock. | 353 // added to the mock. |
| 354 // - GetAddress: | 354 // - GetAddress: |
| 355 // Returns: address | 355 // Returns: address |
| 356 // - GetName: | 356 // - GetName: |
| 357 // Returns: device_name. | 357 // Returns: device_name. |
| 358 // - GetBluetoothClass: | |
| 359 // Returns: 0x1F00. “Unspecified Device Class” see | |
| 360 // bluetooth.org/en-us/specification/assigned-numbers/baseband | |
| 361 // - GetVendorIDSource: | |
| 362 // Returns: BluetoothDevice::VENDOR_ID_BLUETOOTH. | |
| 363 // - GetVendorID: | |
| 364 // Returns: 0xFFFF. | |
| 365 // - GetProductID: | |
| 366 // Returns: 1. | |
| 367 // - GetDeviceID: | |
| 368 // Returns: 2. | |
| 369 // - IsPaired: | 358 // - IsPaired: |
| 370 // Returns true. | 359 // Returns true. |
| 371 static std::unique_ptr<testing::NiceMock<device::MockBluetoothDevice>> | 360 static std::unique_ptr<testing::NiceMock<device::MockBluetoothDevice>> |
| 372 GetBaseDevice(device::MockBluetoothAdapter* adapter, | 361 GetBaseDevice(device::MockBluetoothAdapter* adapter, |
| 373 const std::string& device_name = "Base Device", | 362 const std::string& device_name = "Base Device", |
| 374 device::BluetoothDevice::UUIDList uuids = | 363 device::BluetoothDevice::UUIDList uuids = |
| 375 device::BluetoothDevice::UUIDList(), | 364 device::BluetoothDevice::UUIDList(), |
| 376 const std::string& address = "00:00:00:00:00:00"); | 365 const std::string& address = "00:00:00:00:00:00"); |
| 377 | 366 |
| 378 // |BatteryDevice| | 367 // |BatteryDevice| |
| (...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 621 | 610 |
| 622 // Function to turn an integer into an MAC address of the form | 611 // Function to turn an integer into an MAC address of the form |
| 623 // XX:XX:XX:XX:XX:XX. For example makeMACAddress(0xdeadbeef) | 612 // XX:XX:XX:XX:XX:XX. For example makeMACAddress(0xdeadbeef) |
| 624 // returns "00:00:DE:AD:BE:EF". | 613 // returns "00:00:DE:AD:BE:EF". |
| 625 static std::string makeMACAddress(uint64_t addr); | 614 static std::string makeMACAddress(uint64_t addr); |
| 626 }; | 615 }; |
| 627 | 616 |
| 628 } // namespace content | 617 } // namespace content |
| 629 | 618 |
| 630 #endif // CONTENT_SHELL_BROWSER_LAYOUT_TEST_LAYOUT_TEST_BLUETOOTH_ADAPTER_PROVI
DER_H_ | 619 #endif // CONTENT_SHELL_BROWSER_LAYOUT_TEST_LAYOUT_TEST_BLUETOOTH_ADAPTER_PROVI
DER_H_ |
| OLD | NEW |