| Index: chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui_browsertest-inl.h
|
| diff --git a/chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui_browsertest-inl.h b/chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui_browsertest-inl.h
|
| index 36a2252429fe03cb04a8295547785f3bc26bb968..093f426cec106111ce104420b2d107bc62d0a0e1 100644
|
| --- a/chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui_browsertest-inl.h
|
| +++ b/chrome/browser/ui/webui/chromeos/bluetooth_pairing_ui_browsertest-inl.h
|
| @@ -2,6 +2,7 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| +#include "base/auto_reset.h"
|
| #include "chrome/browser/chromeos/bluetooth/bluetooth_pairing_dialog.h"
|
| #include "chrome/browser/ui/browser.h"
|
| #include "chrome/browser/ui/browser_window.h"
|
| @@ -11,6 +12,7 @@
|
| #include "device/bluetooth/bluetooth_adapter_factory.h"
|
| #include "device/bluetooth/test/mock_bluetooth_adapter.h"
|
| #include "device/bluetooth/test/mock_bluetooth_device.h"
|
| +#include "extensions/browser/extension_function.h"
|
| #include "testing/gmock/include/gmock/gmock.h"
|
|
|
| class BluetoothPairingUITest : public WebUIBrowserTest {
|
| @@ -30,6 +32,10 @@ BluetoothPairingUITest::BluetoothPairingUITest() {}
|
| BluetoothPairingUITest::~BluetoothPairingUITest() {}
|
|
|
| void BluetoothPairingUITest::ShowDialog() {
|
| + // Since we use mocks, callbacks are never called for the bluetooth API
|
| + // functions. :(
|
| + base::AutoReset<bool> ignore_did_respond(
|
| + &ExtensionFunction::ignore_all_did_respond_for_testing_do_not_use, true);
|
| mock_adapter_ = new testing::NiceMock<device::MockBluetoothAdapter>();
|
| device::BluetoothAdapterFactory::SetAdapterForTesting(mock_adapter_);
|
| EXPECT_CALL(*mock_adapter_, IsPresent())
|
|
|