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

Side by Side Diff: chrome/browser/autofill/autofill_manager_unittest.cc

Issue 7740070: Add metrics to measure time elapsed between form load and form submission with or without Autofill. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix compile Created 9 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 <vector> 5 #include <vector>
6 6
7 #include "base/memory/ref_counted.h" 7 #include "base/memory/ref_counted.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/memory/scoped_vector.h" 9 #include "base/memory/scoped_vector.h"
10 #include "base/string16.h" 10 #include "base/string16.h"
(...skipping 498 matching lines...) Expand 10 before | Expand all | Expand 10 after
509 void AutocompleteSuggestionsReturned(const std::vector<string16>& result) { 509 void AutocompleteSuggestionsReturned(const std::vector<string16>& result) {
510 contents_wrapper()->autocomplete_history_manager()-> 510 contents_wrapper()->autocomplete_history_manager()->
511 SendSuggestions(&result); 511 SendSuggestions(&result);
512 } 512 }
513 513
514 void FormsSeen(const std::vector<webkit_glue::FormData>& forms) { 514 void FormsSeen(const std::vector<webkit_glue::FormData>& forms) {
515 autofill_manager_->OnFormsSeen(forms); 515 autofill_manager_->OnFormsSeen(forms);
516 } 516 }
517 517
518 void FormSubmitted(const FormData& form) { 518 void FormSubmitted(const FormData& form) {
519 autofill_manager_->OnFormSubmitted(form); 519 autofill_manager_->OnFormSubmitted(form, 0);
jar (doing other things) 2011/08/31 17:02:21 Here again, I suspect rather than 0, you should su
Ilya Sherman 2011/08/31 21:56:23 This is actually just a filler value to make the c
520 } 520 }
521 521
522 void FillAutofillFormData(int query_id, 522 void FillAutofillFormData(int query_id,
523 const webkit_glue::FormData& form, 523 const webkit_glue::FormData& form,
524 const webkit_glue::FormField& field, 524 const webkit_glue::FormField& field,
525 int unique_id) { 525 int unique_id) {
526 autofill_manager_->OnFillAutofillFormData(query_id, form, field, unique_id); 526 autofill_manager_->OnFillAutofillFormData(query_id, form, field, unique_id);
527 } 527 }
528 528
529 bool GetAutofillSuggestionsMessage(int* page_id, 529 bool GetAutofillSuggestionsMessage(int* page_id,
(...skipping 2241 matching lines...) Expand 10 before | Expand all | Expand 10 after
2771 const FieldTypeSet& possible_types1 = 2771 const FieldTypeSet& possible_types1 =
2772 form_structure.field(1)->possible_types(); 2772 form_structure.field(1)->possible_types();
2773 EXPECT_EQ(1U, possible_types1.size()); 2773 EXPECT_EQ(1U, possible_types1.size());
2774 EXPECT_TRUE(possible_types1.find(NAME_FIRST) != possible_types1.end()); 2774 EXPECT_TRUE(possible_types1.find(NAME_FIRST) != possible_types1.end());
2775 const FieldTypeSet& possible_types2 = 2775 const FieldTypeSet& possible_types2 =
2776 form_structure.field(2)->possible_types(); 2776 form_structure.field(2)->possible_types();
2777 EXPECT_EQ(1U, possible_types2.size()); 2777 EXPECT_EQ(1U, possible_types2.size());
2778 EXPECT_TRUE(possible_types2.find(UNKNOWN_TYPE) != 2778 EXPECT_TRUE(possible_types2.find(UNKNOWN_TYPE) !=
2779 possible_types2.end()); 2779 possible_types2.end());
2780 } 2780 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698