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

Unified Diff: chrome/browser/autofill/autocheckout_manager_unittest.cc

Issue 12091086: [Autofill] Add UMA timing metrics for requestAutocomplete dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase harder Created 7 years, 10 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: chrome/browser/autofill/autocheckout_manager_unittest.cc
diff --git a/chrome/browser/autofill/autocheckout_manager_unittest.cc b/chrome/browser/autofill/autocheckout_manager_unittest.cc
index 5c3857575387e771cd41fbebd9ebdb33456f9816..2d47a2a0ee4d509a3bd8616bb842ba2b8ccc8cff 100644
--- a/chrome/browser/autofill/autocheckout_manager_unittest.cc
+++ b/chrome/browser/autofill/autocheckout_manager_unittest.cc
@@ -23,10 +23,11 @@
using content::BrowserThread;
+namespace autofill {
+
namespace {
-typedef Tuple2<std::vector<FormData>,
- autofill::WebElementDescriptor> AutofillParam;
+typedef Tuple2<std::vector<FormData>, WebElementDescriptor> AutofillParam;
FormFieldData BuildFieldWithValue(
const std::string& autocomplete_attribute,
@@ -158,7 +159,7 @@ scoped_ptr<FormStructure> FakeUserSubmittedFormStructure() {
return form_structure.Pass();
}
-class TestAutofillManagerDelegate : public autofill::AutofillManagerDelegate {
+class TestAutofillManagerDelegate : public AutofillManagerDelegate {
public:
explicit TestAutofillManagerDelegate(
content::BrowserContext* browser_context)
@@ -202,7 +203,7 @@ class TestAutofillManagerDelegate : public autofill::AutofillManagerDelegate {
virtual void ShowPasswordGenerationBubble(
const gfx::Rect& bounds,
const content::PasswordForm& form,
- autofill::PasswordGenerator* generator) OVERRIDE {
+ PasswordGenerator* generator) OVERRIDE {
}
virtual void ShowAutocheckoutBubble(
@@ -216,6 +217,8 @@ class TestAutofillManagerDelegate : public autofill::AutofillManagerDelegate {
const FormData& form,
const GURL& source_url,
const content::SSLStatus& ssl_status,
+ const AutofillMetrics& metric_logger,
+ DialogType dialog_type,
const base::Callback<void(const FormStructure*)>& callback) OVERRIDE {
callback.Run(user_supplied_data_.get());
}
@@ -238,7 +241,7 @@ class TestAutofillManagerDelegate : public autofill::AutofillManagerDelegate {
class TestAutofillManager : public AutofillManager {
public:
explicit TestAutofillManager(content::WebContents* contents,
- autofill::AutofillManagerDelegate* delegate)
+ AutofillManagerDelegate* delegate)
: AutofillManager(contents, delegate, NULL) {
}
@@ -306,10 +309,9 @@ TEST_F(AutocheckoutManagerTest, TestFillForms) {
FakeUserSubmittedFormStructure());
// Set up page meta data.
- scoped_ptr<autofill::AutocheckoutPageMetaData> page_meta_data(
- new autofill::AutocheckoutPageMetaData());
- page_meta_data->proceed_element_descriptor.reset(
- new autofill::WebElementDescriptor());
+ scoped_ptr<AutocheckoutPageMetaData> page_meta_data(
+ new AutocheckoutPageMetaData());
+ page_meta_data->proceed_element_descriptor.reset(new WebElementDescriptor());
autocheckout_manager_->OnLoadedPageMetaData(page_meta_data.Pass());
GURL frame_url;
@@ -369,3 +371,5 @@ TEST_F(AutocheckoutManagerTest, TestFillForms) {
EXPECT_TRUE(filled_forms[0].fields[1].is_checked);
EXPECT_EQ(ASCIIToUTF16("female"), filled_forms[0].fields[1].value);
}
+
+} // namespace autofill
« no previous file with comments | « chrome/browser/autofill/autocheckout_manager.cc ('k') | chrome/browser/autofill/autofill_external_delegate_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698