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

Unified Diff: components/autofill/browser/autofill_metrics_unittest.cc

Issue 13264002: Requery the autofill server when forms and input fields are dynamically added. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 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/browser/autofill_metrics_unittest.cc
diff --git a/components/autofill/browser/autofill_metrics_unittest.cc b/components/autofill/browser/autofill_metrics_unittest.cc
index f214e4783c7e341136d539268e9a05e8aae9c6f4..1cf580d2acf23b59654fc3ef66fac83eb2bf19ed 100644
--- a/components/autofill/browser/autofill_metrics_unittest.cc
+++ b/components/autofill/browser/autofill_metrics_unittest.cc
@@ -787,7 +787,7 @@ TEST_F(AutofillMetricsTest, DeveloperEngagement) {
{
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogDeveloperEngagementMetric(_)).Times(0);
- autofill_manager_->OnFormsSeen(forms, TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(forms, TimeTicks(), false, false);
ahutter 2013/03/29 19:48:31 Might want to add a TODO somewhere to collect metr
Dane Wallinga 2013/03/29 21:41:12 Is it just that the current code path doesn't dist
ahutter 2013/03/29 21:53:08 Just no UMA metrics for these new kinds of forms w
Dane Wallinga 2013/04/02 19:50:53 will do
autofill_manager_->Reset();
Mock::VerifyAndClearExpectations(autofill_manager_->metric_logger());
}
@@ -807,7 +807,7 @@ TEST_F(AutofillMetricsTest, DeveloperEngagement) {
*autofill_manager_->metric_logger(),
LogDeveloperEngagementMetric(
AutofillMetrics::FILLABLE_FORM_CONTAINS_TYPE_HINTS)).Times(0);
- autofill_manager_->OnFormsSeen(forms, TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(forms, TimeTicks(), false, false);
autofill_manager_->Reset();
Mock::VerifyAndClearExpectations(autofill_manager_->metric_logger());
}
@@ -838,7 +838,7 @@ TEST_F(AutofillMetricsTest, DeveloperEngagement) {
*autofill_manager_->metric_logger(),
LogDeveloperEngagementMetric(
AutofillMetrics::FILLABLE_FORM_CONTAINS_TYPE_HINTS)).Times(1);
- autofill_manager_->OnFormsSeen(forms, TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(forms, TimeTicks(), false, false);
autofill_manager_->Reset();
Mock::VerifyAndClearExpectations(autofill_manager_->metric_logger());
}
@@ -1117,7 +1117,7 @@ TEST_F(AutofillMetricsTest, AutofillIsEnabledAtPageLoad) {
LogIsAutofillEnabledAtPageLoad(true)).Times(1);
autofill_manager_->set_autofill_enabled(true);
- autofill_manager_->OnFormsSeen(std::vector<FormData>(), TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(std::vector<FormData>(), TimeTicks(), false, false);
// Reset the autofill manager state.
autofill_manager_->Reset();
@@ -1127,7 +1127,7 @@ TEST_F(AutofillMetricsTest, AutofillIsEnabledAtPageLoad) {
LogIsAutofillEnabledAtPageLoad(false)).Times(1);
autofill_manager_->set_autofill_enabled(false);
- autofill_manager_->OnFormsSeen(std::vector<FormData>(), TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(std::vector<FormData>(), TimeTicks(), false, false);
}
// Test that credit card infobar metrics are logged correctly.
@@ -1240,7 +1240,7 @@ TEST_F(AutofillMetricsTest, UserHappinessFormLoadAndSubmission) {
{
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogUserHappinessMetric(AutofillMetrics::FORMS_LOADED)).Times(0);
- autofill_manager_->OnFormsSeen(forms, TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(forms, TimeTicks(), false, false);
}
@@ -1276,7 +1276,7 @@ TEST_F(AutofillMetricsTest, UserHappinessFormLoadAndSubmission) {
{
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogUserHappinessMetric(AutofillMetrics::FORMS_LOADED));
- autofill_manager_->OnFormsSeen(forms, TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(forms, TimeTicks(), false, false);
}
// Expect a notification when the form is submitted.
@@ -1376,7 +1376,7 @@ TEST_F(AutofillMetricsTest, UserHappinessFormInteraction) {
{
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogUserHappinessMetric(AutofillMetrics::FORMS_LOADED));
- autofill_manager_->OnFormsSeen(forms, TimeTicks(), false);
+ autofill_manager_->OnFormsSeen(forms, TimeTicks(), false, false);
}
// Simulate typing.
@@ -1496,7 +1496,7 @@ TEST_F(AutofillMetricsTest, FormFillDuration) {
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogFormFillDurationFromInteractionWithoutAutofill(_)).Times(0);
autofill_manager_->OnFormsSeen(
- forms, TimeTicks::FromInternalValue(1), false);
+ forms, TimeTicks::FromInternalValue(1), false, false);
autofill_manager_->FormSubmitted(form, TimeTicks::FromInternalValue(17));
autofill_manager_->Reset();
Mock::VerifyAndClearExpectations(autofill_manager_->metric_logger());
@@ -1515,7 +1515,7 @@ TEST_F(AutofillMetricsTest, FormFillDuration) {
LogFormFillDurationFromInteractionWithoutAutofill(
TimeDelta::FromInternalValue(14)));
autofill_manager_->OnFormsSeen(
- forms, TimeTicks::FromInternalValue(1), false);
+ forms, TimeTicks::FromInternalValue(1), false, false);
autofill_manager_->OnTextFieldDidChange(form, form.fields.front(),
TimeTicks::FromInternalValue(3));
autofill_manager_->FormSubmitted(form, TimeTicks::FromInternalValue(17));
@@ -1537,7 +1537,7 @@ TEST_F(AutofillMetricsTest, FormFillDuration) {
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogFormFillDurationFromInteractionWithoutAutofill(_)).Times(0);
autofill_manager_->OnFormsSeen(
- forms, TimeTicks::FromInternalValue(1), false);
+ forms, TimeTicks::FromInternalValue(1), false, false);
autofill_manager_->OnDidFillAutofillFormData(
TimeTicks::FromInternalValue(5));
autofill_manager_->FormSubmitted(form, TimeTicks::FromInternalValue(17));
@@ -1560,7 +1560,7 @@ TEST_F(AutofillMetricsTest, FormFillDuration) {
EXPECT_CALL(*autofill_manager_->metric_logger(),
LogFormFillDurationFromInteractionWithoutAutofill(_)).Times(0);
autofill_manager_->OnFormsSeen(
- forms, TimeTicks::FromInternalValue(1), false);
+ forms, TimeTicks::FromInternalValue(1), false, false);
autofill_manager_->OnDidFillAutofillFormData(
TimeTicks::FromInternalValue(5));
autofill_manager_->OnTextFieldDidChange(form, form.fields.front(),

Powered by Google App Engine
This is Rietveld 408576698