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

Unified Diff: components/autofill/core/browser/test_autofill_client.h

Issue 2740633002: [Autofill] Add upstreaming UKM (Closed)
Patch Set: Fixed comments Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: components/autofill/core/browser/test_autofill_client.h
diff --git a/components/autofill/core/browser/test_autofill_client.h b/components/autofill/core/browser/test_autofill_client.h
index 72cdd8c3f5757accc172498b2d6de0e88059b979..5b25ecfabab9796e5c913bdafccb807ba248a5d6 100644
--- a/components/autofill/core/browser/test_autofill_client.h
+++ b/components/autofill/core/browser/test_autofill_client.h
@@ -16,6 +16,7 @@
#include "components/autofill/core/browser/autofill_client.h"
#include "components/prefs/pref_service.h"
#include "components/rappor/test_rappor_service.h"
+#include "components/ukm/test_ukm_service.h"
#include "google_apis/gaia/fake_identity_provider.h"
#include "google_apis/gaia/fake_oauth2_token_service.h"
@@ -34,6 +35,7 @@ class TestAutofillClient : public AutofillClient {
syncer::SyncService* GetSyncService() override;
IdentityProvider* GetIdentityProvider() override;
rappor::RapporServiceImpl* GetRapporServiceImpl() override;
+ ukm::UkmService* GetUkmService() override;
void ShowAutofillSettings() override;
void ShowUnmaskPrompt(const CreditCard& card,
UnmaskCardReason reason,
@@ -85,12 +87,17 @@ class TestAutofillClient : public AutofillClient {
void set_form_origin(const GURL& url) { form_origin_ = url; }
+ ukm::TestUkmService* GetTestUkmService() {
+ return ukm_service_test_harness_.test_ukm_service();
+ }
+
private:
// NULL by default.
std::unique_ptr<PrefService> prefs_;
std::unique_ptr<FakeOAuth2TokenService> token_service_;
std::unique_ptr<FakeIdentityProvider> identity_provider_;
std::unique_ptr<rappor::TestRapporServiceImpl> rappor_service_;
+ ukm::UkmServiceTestingHarness ukm_service_test_harness_;
GURL form_origin_;
DISALLOW_COPY_AND_ASSIGN(TestAutofillClient);

Powered by Google App Engine
This is Rietveld 408576698