| 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 #include "components/autofill/core/browser/test_autofill_client.h" | 5 #include "components/autofill/core/browser/test_autofill_client.h" |
| 6 | 6 |
| 7 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" | 7 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" |
| 8 | 8 |
| 9 namespace autofill { | 9 namespace autofill { |
| 10 | 10 |
| 11 TestAutofillClient::TestAutofillClient() | 11 TestAutofillClient::TestAutofillClient() |
| 12 : token_service_(new FakeOAuth2TokenService()), | 12 : token_service_(new FakeOAuth2TokenService()), |
| 13 identity_provider_(new FakeIdentityProvider(token_service_.get())), | 13 identity_provider_(new FakeIdentityProvider(token_service_.get())), |
| 14 rappor_service_(new rappor::TestRapporService()) {} | 14 rappor_service_(new rappor::TestRapporServiceImpl()) {} |
| 15 | 15 |
| 16 TestAutofillClient::~TestAutofillClient() { | 16 TestAutofillClient::~TestAutofillClient() { |
| 17 } | 17 } |
| 18 | 18 |
| 19 PersonalDataManager* TestAutofillClient::GetPersonalDataManager() { | 19 PersonalDataManager* TestAutofillClient::GetPersonalDataManager() { |
| 20 return nullptr; | 20 return nullptr; |
| 21 } | 21 } |
| 22 | 22 |
| 23 scoped_refptr<AutofillWebDataService> TestAutofillClient::GetDatabase() { | 23 scoped_refptr<AutofillWebDataService> TestAutofillClient::GetDatabase() { |
| 24 return scoped_refptr<AutofillWebDataService>(nullptr); | 24 return scoped_refptr<AutofillWebDataService>(nullptr); |
| 25 } | 25 } |
| 26 | 26 |
| 27 PrefService* TestAutofillClient::GetPrefs() { | 27 PrefService* TestAutofillClient::GetPrefs() { |
| 28 return prefs_.get(); | 28 return prefs_.get(); |
| 29 } | 29 } |
| 30 | 30 |
| 31 syncer::SyncService* TestAutofillClient::GetSyncService() { | 31 syncer::SyncService* TestAutofillClient::GetSyncService() { |
| 32 return nullptr; | 32 return nullptr; |
| 33 } | 33 } |
| 34 | 34 |
| 35 IdentityProvider* TestAutofillClient::GetIdentityProvider() { | 35 IdentityProvider* TestAutofillClient::GetIdentityProvider() { |
| 36 return identity_provider_.get(); | 36 return identity_provider_.get(); |
| 37 } | 37 } |
| 38 | 38 |
| 39 rappor::RapporService* TestAutofillClient::GetRapporService() { | 39 rappor::RapporServiceImpl* TestAutofillClient::GetRapporServiceImpl() { |
| 40 return rappor_service_.get(); | 40 return rappor_service_.get(); |
| 41 } | 41 } |
| 42 | 42 |
| 43 void TestAutofillClient::ShowAutofillSettings() { | 43 void TestAutofillClient::ShowAutofillSettings() { |
| 44 } | 44 } |
| 45 | 45 |
| 46 void TestAutofillClient::ShowUnmaskPrompt( | 46 void TestAutofillClient::ShowUnmaskPrompt( |
| 47 const CreditCard& card, | 47 const CreditCard& card, |
| 48 UnmaskCardReason reason, | 48 UnmaskCardReason reason, |
| 49 base::WeakPtr<CardUnmaskDelegate> delegate) { | 49 base::WeakPtr<CardUnmaskDelegate> delegate) { |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 return form_origin.SchemeIs("https"); | 120 return form_origin.SchemeIs("https"); |
| 121 } | 121 } |
| 122 | 122 |
| 123 bool TestAutofillClient::ShouldShowSigninPromo() { | 123 bool TestAutofillClient::ShouldShowSigninPromo() { |
| 124 return false; | 124 return false; |
| 125 } | 125 } |
| 126 | 126 |
| 127 void TestAutofillClient::StartSigninFlow() {} | 127 void TestAutofillClient::StartSigninFlow() {} |
| 128 | 128 |
| 129 } // namespace autofill | 129 } // namespace autofill |
| OLD | NEW |