| 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 CHROME_BROWSER_PASSWORD_MANAGER_MOCK_PASSWORD_STORE_H_ | 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_MOCK_PASSWORD_STORE_H_ |
| 6 #define CHROME_BROWSER_PASSWORD_MANAGER_MOCK_PASSWORD_STORE_H_ | 6 #define CHROME_BROWSER_PASSWORD_MANAGER_MOCK_PASSWORD_STORE_H_ |
| 7 | 7 |
| 8 #include "chrome/browser/password_manager/password_store.h" | 8 #include "chrome/browser/password_manager/password_store.h" |
| 9 #include "content/public/common/password_form.h" | 9 #include "content/public/common/password_form.h" |
| 10 #include "testing/gmock/include/gmock/gmock.h" | 10 #include "testing/gmock/include/gmock/gmock.h" |
| 11 | 11 |
| 12 namespace content { | 12 namespace content { |
| 13 class BrowserContext; | 13 class BrowserContext; |
| 14 } | 14 } |
| 15 | 15 |
| 16 class MockPasswordStore : public PasswordStore { | 16 class MockPasswordStore : public PasswordStore { |
| 17 public: | 17 public: |
| 18 MockPasswordStore(); | 18 MockPasswordStore(); |
| 19 | 19 |
| 20 static scoped_refptr<RefcountedProfileKeyedService> Build( | 20 static scoped_refptr<RefcountedBrowserContextKeyedService> Build( |
| 21 content::BrowserContext* profile); | 21 content::BrowserContext* profile); |
| 22 | 22 |
| 23 MOCK_METHOD1(RemoveLogin, void(const content::PasswordForm&)); | 23 MOCK_METHOD1(RemoveLogin, void(const content::PasswordForm&)); |
| 24 MOCK_METHOD2(GetLogins, | 24 MOCK_METHOD2(GetLogins, |
| 25 CancelableTaskTracker::TaskId(const content::PasswordForm&, | 25 CancelableTaskTracker::TaskId(const content::PasswordForm&, |
| 26 PasswordStoreConsumer*)); | 26 PasswordStoreConsumer*)); |
| 27 MOCK_METHOD1(AddLogin, void(const content::PasswordForm&)); | 27 MOCK_METHOD1(AddLogin, void(const content::PasswordForm&)); |
| 28 MOCK_METHOD1(UpdateLogin, void(const content::PasswordForm&)); | 28 MOCK_METHOD1(UpdateLogin, void(const content::PasswordForm&)); |
| 29 MOCK_METHOD0(ReportMetrics, void()); | 29 MOCK_METHOD0(ReportMetrics, void()); |
| 30 MOCK_METHOD0(ReportMetricsImpl, void()); | 30 MOCK_METHOD0(ReportMetricsImpl, void()); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 43 MOCK_METHOD1(FillBlacklistLogins, | 43 MOCK_METHOD1(FillBlacklistLogins, |
| 44 bool(std::vector<content::PasswordForm*>*)); | 44 bool(std::vector<content::PasswordForm*>*)); |
| 45 | 45 |
| 46 virtual void ShutdownOnUIThread(); | 46 virtual void ShutdownOnUIThread(); |
| 47 | 47 |
| 48 protected: | 48 protected: |
| 49 virtual ~MockPasswordStore(); | 49 virtual ~MockPasswordStore(); |
| 50 }; | 50 }; |
| 51 | 51 |
| 52 #endif // CHROME_BROWSER_PASSWORD_MANAGER_MOCK_PASSWORD_STORE_H_ | 52 #endif // CHROME_BROWSER_PASSWORD_MANAGER_MOCK_PASSWORD_STORE_H_ |
| OLD | NEW |