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

Side by Side Diff: chromeos/dbus/mock_dbus_thread_manager.cc

Issue 10546010: Implement support for the OOB Pairing APIs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: refactor to create BluetoothOutOfBandClient Created 8 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chromeos/dbus/mock_dbus_thread_manager.h" 5 #include "chromeos/dbus/mock_dbus_thread_manager.h"
6 6
7 #include "chromeos/dbus/ibus/mock_ibus_client.h" 7 #include "chromeos/dbus/ibus/mock_ibus_client.h"
8 #include "chromeos/dbus/ibus/mock_ibus_input_context_client.h" 8 #include "chromeos/dbus/ibus/mock_ibus_input_context_client.h"
9 #include "chromeos/dbus/mock_bluetooth_adapter_client.h" 9 #include "chromeos/dbus/mock_bluetooth_adapter_client.h"
10 #include "chromeos/dbus/mock_bluetooth_device_client.h" 10 #include "chromeos/dbus/mock_bluetooth_device_client.h"
11 #include "chromeos/dbus/mock_bluetooth_input_client.h" 11 #include "chromeos/dbus/mock_bluetooth_input_client.h"
12 #include "chromeos/dbus/mock_bluetooth_manager_client.h" 12 #include "chromeos/dbus/mock_bluetooth_manager_client.h"
13 #include "chromeos/dbus/mock_bluetooth_node_client.h" 13 #include "chromeos/dbus/mock_bluetooth_node_client.h"
14 #include "chromeos/dbus/mock_bluetooth_out_of_band_client.h"
14 #include "chromeos/dbus/mock_cashew_client.h" 15 #include "chromeos/dbus/mock_cashew_client.h"
15 #include "chromeos/dbus/mock_cros_disks_client.h" 16 #include "chromeos/dbus/mock_cros_disks_client.h"
16 #include "chromeos/dbus/mock_cryptohome_client.h" 17 #include "chromeos/dbus/mock_cryptohome_client.h"
17 #include "chromeos/dbus/mock_debug_daemon_client.h" 18 #include "chromeos/dbus/mock_debug_daemon_client.h"
18 #include "chromeos/dbus/mock_flimflam_device_client.h" 19 #include "chromeos/dbus/mock_flimflam_device_client.h"
19 #include "chromeos/dbus/mock_flimflam_ipconfig_client.h" 20 #include "chromeos/dbus/mock_flimflam_ipconfig_client.h"
20 #include "chromeos/dbus/mock_flimflam_manager_client.h" 21 #include "chromeos/dbus/mock_flimflam_manager_client.h"
21 #include "chromeos/dbus/mock_flimflam_network_client.h" 22 #include "chromeos/dbus/mock_flimflam_network_client.h"
22 #include "chromeos/dbus/mock_flimflam_profile_client.h" 23 #include "chromeos/dbus/mock_flimflam_profile_client.h"
23 #include "chromeos/dbus/mock_flimflam_service_client.h" 24 #include "chromeos/dbus/mock_flimflam_service_client.h"
(...skipping 10 matching lines...) Expand all
34 using ::testing::_; 35 using ::testing::_;
35 36
36 namespace chromeos { 37 namespace chromeos {
37 38
38 MockDBusThreadManager::MockDBusThreadManager() 39 MockDBusThreadManager::MockDBusThreadManager()
39 : mock_bluetooth_adapter_client_(new MockBluetoothAdapterClient), 40 : mock_bluetooth_adapter_client_(new MockBluetoothAdapterClient),
40 mock_bluetooth_device_client_(new MockBluetoothDeviceClient), 41 mock_bluetooth_device_client_(new MockBluetoothDeviceClient),
41 mock_bluetooth_input_client_(new MockBluetoothInputClient), 42 mock_bluetooth_input_client_(new MockBluetoothInputClient),
42 mock_bluetooth_manager_client_(new MockBluetoothManagerClient), 43 mock_bluetooth_manager_client_(new MockBluetoothManagerClient),
43 mock_bluetooth_node_client_(new MockBluetoothNodeClient), 44 mock_bluetooth_node_client_(new MockBluetoothNodeClient),
45 mock_bluetooth_out_of_band_client_(new MockBluetoothOutOfBandClient),
44 mock_cashew_client_(new MockCashewClient), 46 mock_cashew_client_(new MockCashewClient),
45 mock_cros_disks_client_(new MockCrosDisksClient), 47 mock_cros_disks_client_(new MockCrosDisksClient),
46 mock_cryptohome_client_(new MockCryptohomeClient), 48 mock_cryptohome_client_(new MockCryptohomeClient),
47 mock_debugdaemon_client_(new MockDebugDaemonClient), 49 mock_debugdaemon_client_(new MockDebugDaemonClient),
48 mock_flimflam_device_client_(new MockFlimflamDeviceClient), 50 mock_flimflam_device_client_(new MockFlimflamDeviceClient),
49 mock_flimflam_ipconfig_client_(new MockFlimflamIPConfigClient), 51 mock_flimflam_ipconfig_client_(new MockFlimflamIPConfigClient),
50 mock_flimflam_manager_client_(new MockFlimflamManagerClient), 52 mock_flimflam_manager_client_(new MockFlimflamManagerClient),
51 mock_flimflam_network_client_(new MockFlimflamNetworkClient), 53 mock_flimflam_network_client_(new MockFlimflamNetworkClient),
52 mock_flimflam_profile_client_(new MockFlimflamProfileClient), 54 mock_flimflam_profile_client_(new MockFlimflamProfileClient),
53 mock_flimflam_service_client_(new MockFlimflamServiceClient), 55 mock_flimflam_service_client_(new MockFlimflamServiceClient),
54 mock_gsm_sms_client_(new MockGsmSMSClient), 56 mock_gsm_sms_client_(new MockGsmSMSClient),
55 mock_image_burner_client_(new MockImageBurnerClient), 57 mock_image_burner_client_(new MockImageBurnerClient),
56 mock_introspectable_client_(new MockIntrospectableClient), 58 mock_introspectable_client_(new MockIntrospectableClient),
57 mock_power_manager_client_(new MockPowerManagerClient), 59 mock_power_manager_client_(new MockPowerManagerClient),
58 mock_session_manager_client_(new MockSessionManagerClient), 60 mock_session_manager_client_(new MockSessionManagerClient),
59 mock_speech_synthesizer_client_(new MockSpeechSynthesizerClient), 61 mock_speech_synthesizer_client_(new MockSpeechSynthesizerClient),
60 mock_update_engine_client_(new MockUpdateEngineClient), 62 mock_update_engine_client_(new MockUpdateEngineClient),
61 mock_ibus_client_(new MockIBusClient), 63 mock_ibus_client_(new MockIBusClient),
62 mock_ibus_input_context_client_(new MockIBusInputContextClient) { 64 mock_ibus_input_context_client_(new MockIBusInputContextClient) {
63 EXPECT_CALL(*this, GetBluetoothAdapterClient()) 65 EXPECT_CALL(*this, GetBluetoothAdapterClient())
64 .WillRepeatedly(Return(mock_bluetooth_adapter_client_.get())); 66 .WillRepeatedly(Return(mock_bluetooth_adapter_client_.get()));
65 EXPECT_CALL(*this, GetBluetoothDeviceClient()) 67 EXPECT_CALL(*this, GetBluetoothDeviceClient())
66 .WillRepeatedly(Return(mock_bluetooth_device_client_.get())); 68 .WillRepeatedly(Return(mock_bluetooth_device_client_.get()));
67 EXPECT_CALL(*this, GetBluetoothInputClient()) 69 EXPECT_CALL(*this, GetBluetoothInputClient())
68 .WillRepeatedly(Return(mock_bluetooth_input_client_.get())); 70 .WillRepeatedly(Return(mock_bluetooth_input_client_.get()));
69 EXPECT_CALL(*this, GetBluetoothManagerClient()) 71 EXPECT_CALL(*this, GetBluetoothManagerClient())
70 .WillRepeatedly(Return(mock_bluetooth_manager_client())); 72 .WillRepeatedly(Return(mock_bluetooth_manager_client()));
71 EXPECT_CALL(*this, GetBluetoothNodeClient()) 73 EXPECT_CALL(*this, GetBluetoothNodeClient())
72 .WillRepeatedly(Return(mock_bluetooth_node_client_.get())); 74 .WillRepeatedly(Return(mock_bluetooth_node_client_.get()));
75 EXPECT_CALL(*this, GetBluetoothOutOfBandClient())
76 .WillRepeatedly(Return(mock_bluetooth_out_of_band_client_.get()));
73 EXPECT_CALL(*this, GetCashewClient()) 77 EXPECT_CALL(*this, GetCashewClient())
74 .WillRepeatedly(Return(mock_cashew_client())); 78 .WillRepeatedly(Return(mock_cashew_client()));
75 EXPECT_CALL(*this, GetCrosDisksClient()) 79 EXPECT_CALL(*this, GetCrosDisksClient())
76 .WillRepeatedly(Return(mock_cros_disks_client())); 80 .WillRepeatedly(Return(mock_cros_disks_client()));
77 EXPECT_CALL(*this, GetCryptohomeClient()) 81 EXPECT_CALL(*this, GetCryptohomeClient())
78 .WillRepeatedly(Return(mock_cryptohome_client())); 82 .WillRepeatedly(Return(mock_cryptohome_client()));
79 EXPECT_CALL(*this, GetDebugDaemonClient()) 83 EXPECT_CALL(*this, GetDebugDaemonClient())
80 .WillRepeatedly(Return(mock_debugdaemon_client())); 84 .WillRepeatedly(Return(mock_debugdaemon_client()));
81 EXPECT_CALL(*this, GetFlimflamDeviceClient()) 85 EXPECT_CALL(*this, GetFlimflamDeviceClient())
82 .WillRepeatedly(Return(mock_flimflam_device_client())); 86 .WillRepeatedly(Return(mock_flimflam_device_client()));
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 .Times(AnyNumber()); 132 .Times(AnyNumber());
129 133
130 // Called from DiskMountManager::Initialize(), ChromeBrowserMainPartsChromeos. 134 // Called from DiskMountManager::Initialize(), ChromeBrowserMainPartsChromeos.
131 EXPECT_CALL(*mock_cros_disks_client_.get(), SetUpConnections(_, _)) 135 EXPECT_CALL(*mock_cros_disks_client_.get(), SetUpConnections(_, _))
132 .Times(AnyNumber()); 136 .Times(AnyNumber());
133 } 137 }
134 138
135 MockDBusThreadManager::~MockDBusThreadManager() {} 139 MockDBusThreadManager::~MockDBusThreadManager() {}
136 140
137 } // namespace chromeos 141 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698