OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_AUTOFILL_CORE_BROWSER_TEST_AUTOFILL_CLIENT_H_ | 5 #ifndef COMPONENTS_AUTOFILL_CORE_BROWSER_TEST_AUTOFILL_CLIENT_H_ |
6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_TEST_AUTOFILL_CLIENT_H_ | 6 #define COMPONENTS_AUTOFILL_CORE_BROWSER_TEST_AUTOFILL_CLIENT_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/i18n/rtl.h" | 9 #include "base/i18n/rtl.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
11 #include "base/prefs/pref_service.h" | 11 #include "base/prefs/pref_service.h" |
12 #include "components/autofill/core/browser/autofill_client.h" | 12 #include "components/autofill/core/browser/autofill_client.h" |
13 | 13 |
14 namespace autofill { | 14 namespace autofill { |
15 | 15 |
16 // This class is for easier writing of tests. | 16 // This class is for easier writing of tests. |
17 class TestAutofillClient : public AutofillClient { | 17 class TestAutofillClient : public AutofillClient { |
18 public: | 18 public: |
19 TestAutofillClient(); | 19 TestAutofillClient(); |
20 ~TestAutofillClient() override; | 20 ~TestAutofillClient() override; |
21 | 21 |
22 // AutofillClient implementation. | 22 // AutofillClient implementation. |
23 PersonalDataManager* GetPersonalDataManager() override; | 23 PersonalDataManager* GetPersonalDataManager() override; |
24 scoped_refptr<AutofillWebDataService> GetDatabase() override; | 24 scoped_refptr<AutofillWebDataService> GetDatabase() override; |
25 PrefService* GetPrefs() override; | 25 PrefService* GetPrefs() override; |
| 26 IdentityProvider* GetIdentityProvider() override; |
26 void HideRequestAutocompleteDialog() override; | 27 void HideRequestAutocompleteDialog() override; |
27 void ShowAutofillSettings() override; | 28 void ShowAutofillSettings() override; |
28 void ShowUnmaskPrompt(const CreditCard& card, | 29 void ShowUnmaskPrompt(const CreditCard& card, |
29 base::WeakPtr<CardUnmaskDelegate> delegate) override; | 30 base::WeakPtr<CardUnmaskDelegate> delegate) override; |
30 void OnUnmaskVerificationResult(bool success) override; | 31 void OnUnmaskVerificationResult(bool success) override; |
31 void ConfirmSaveCreditCard(const base::Closure& save_card_callback) override; | 32 void ConfirmSaveCreditCard(const base::Closure& save_card_callback) override; |
32 bool HasCreditCardScanFeature() override; | 33 bool HasCreditCardScanFeature() override; |
33 void ScanCreditCard(const CreditCardScanCallback& callback) override; | 34 void ScanCreditCard(const CreditCardScanCallback& callback) override; |
34 void ShowRequestAutocompleteDialog(const FormData& form, | 35 void ShowRequestAutocompleteDialog(const FormData& form, |
35 content::RenderFrameHost* rfh, | 36 content::RenderFrameHost* rfh, |
(...skipping 21 matching lines...) Expand all Loading... |
57 private: | 58 private: |
58 // NULL by default. | 59 // NULL by default. |
59 scoped_ptr<PrefService> prefs_; | 60 scoped_ptr<PrefService> prefs_; |
60 | 61 |
61 DISALLOW_COPY_AND_ASSIGN(TestAutofillClient); | 62 DISALLOW_COPY_AND_ASSIGN(TestAutofillClient); |
62 }; | 63 }; |
63 | 64 |
64 } // namespace autofill | 65 } // namespace autofill |
65 | 66 |
66 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_TEST_AUTOFILL_CLIENT_H_ | 67 #endif // COMPONENTS_AUTOFILL_CORE_BROWSER_TEST_AUTOFILL_CLIENT_H_ |
OLD | NEW |