OLD | NEW |
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 #ifndef CHROMEOS_DBUS_MOCK_CRYPTOHOME_CLIENT_H_ | 5 #ifndef CHROMEOS_DBUS_MOCK_CRYPTOHOME_CLIENT_H_ |
6 #define CHROMEOS_DBUS_MOCK_CRYPTOHOME_CLIENT_H_ | 6 #define CHROMEOS_DBUS_MOCK_CRYPTOHOME_CLIENT_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "chromeos/dbus/cryptohome_client.h" | 10 #include "chromeos/dbus/cryptohome_client.h" |
11 #include "testing/gmock/include/gmock/gmock.h" | 11 #include "testing/gmock/include/gmock/gmock.h" |
12 | 12 |
13 namespace chromeos { | 13 namespace chromeos { |
14 | 14 |
15 class MockCryptohomeClient : public CryptohomeClient { | 15 class MockCryptohomeClient : public CryptohomeClient { |
16 public: | 16 public: |
17 MockCryptohomeClient(); | 17 MockCryptohomeClient(); |
18 virtual ~MockCryptohomeClient(); | 18 virtual ~MockCryptohomeClient(); |
19 | 19 |
20 MOCK_METHOD1(Init, void(dbus::Bus* bus)); | 20 MOCK_METHOD1(Init, void(dbus::Bus* bus)); |
21 MOCK_METHOD2(SetAsyncCallStatusHandlers, | 21 MOCK_METHOD2(SetAsyncCallStatusHandlers, |
22 void(const AsyncCallStatusHandler& handler, | 22 void(const AsyncCallStatusHandler& handler, |
23 const AsyncCallStatusWithDataHandler& data_handler)); | 23 const AsyncCallStatusWithDataHandler& data_handler)); |
24 MOCK_METHOD0(ResetAsyncCallStatusHandlers, void()); | 24 MOCK_METHOD0(ResetAsyncCallStatusHandlers, void()); |
| 25 MOCK_METHOD1(WaitForServiceToBeAvailable, |
| 26 void(const WaitForServiceToBeAvailableCallback& callback)); |
25 MOCK_METHOD1(IsMounted, void(const BoolDBusMethodCallback& callback)); | 27 MOCK_METHOD1(IsMounted, void(const BoolDBusMethodCallback& callback)); |
26 MOCK_METHOD1(Unmount, bool(bool* success)); | 28 MOCK_METHOD1(Unmount, bool(bool* success)); |
27 MOCK_METHOD3(AsyncCheckKey, | 29 MOCK_METHOD3(AsyncCheckKey, |
28 void(const std::string& username, | 30 void(const std::string& username, |
29 const std::string& key, | 31 const std::string& key, |
30 const AsyncMethodCallback& callback)); | 32 const AsyncMethodCallback& callback)); |
31 MOCK_METHOD4(AsyncMigrateKey, | 33 MOCK_METHOD4(AsyncMigrateKey, |
32 void(const std::string& username, | 34 void(const std::string& username, |
33 const std::string& from_key, | 35 const std::string& from_key, |
34 const std::string& to_key, | 36 const std::string& to_key, |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 void(attestation::AttestationKeyType key_type, | 154 void(attestation::AttestationKeyType key_type, |
153 const std::string& user_id, | 155 const std::string& user_id, |
154 const std::string& key_name, | 156 const std::string& key_name, |
155 const std::string& payload, | 157 const std::string& payload, |
156 const BoolDBusMethodCallback& callback)); | 158 const BoolDBusMethodCallback& callback)); |
157 }; | 159 }; |
158 | 160 |
159 } // namespace chromeos | 161 } // namespace chromeos |
160 | 162 |
161 #endif // CHROMEOS_DBUS_MOCK_CRYPTOHOME_CLIENT_H_ | 163 #endif // CHROMEOS_DBUS_MOCK_CRYPTOHOME_CLIENT_H_ |
OLD | NEW |