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

Unified Diff: chrome/renderer/autofill/form_autofill_browsertest.cc

Issue 704133006: Cleanup: Remove FormWithElementIsAutofilled(). It's not used. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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
« no previous file with comments | « no previous file | components/autofill/content/renderer/form_autofill_util.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/autofill/form_autofill_browsertest.cc
diff --git a/chrome/renderer/autofill/form_autofill_browsertest.cc b/chrome/renderer/autofill/form_autofill_browsertest.cc
index 4991bbcf3fac50a55ec12163da75b0e03e883827..70144c140228bc3a8d3ebc40d978cfcd5cd74c19 100644
--- a/chrome/renderer/autofill/form_autofill_browsertest.cc
+++ b/chrome/renderer/autofill/form_autofill_browsertest.cc
@@ -3481,35 +3481,6 @@ TEST_F(FormAutofillTest, ClearOnlyAutofilledFields) {
EXPECT_FALSE(phone.isAutofilled());
}
-TEST_F(FormAutofillTest, FormWithNodeIsAutofilled) {
- LoadHTML("<FORM name='TestForm' action='http://buh.com' method='post'>"
- " <INPUT type='text' id='firstname' value='Wyatt'/>"
- " <INPUT type='text' id='lastname'/>"
- " <INPUT type='text' id='email'/>"
- " <INPUT type='email' id='email2'/>"
- " <INPUT type='tel' id='phone'/>"
- " <INPUT type='submit' value='Send'/>"
- "</FORM>");
-
- WebFrame* web_frame = GetMainFrame();
- ASSERT_NE(static_cast<WebFrame*>(NULL), web_frame);
-
- FormCache form_cache;
- std::vector<FormData> forms = form_cache.ExtractNewForms(*web_frame);
- ASSERT_EQ(1U, forms.size());
-
- WebInputElement firstname =
- web_frame->document().getElementById("firstname").to<WebInputElement>();
-
- // Auto-filled attribute not set yet.
- EXPECT_FALSE(FormWithElementIsAutofilled(firstname));
-
- // Set the auto-filled attribute.
- firstname.setAutofilled(true);
-
- EXPECT_TRUE(FormWithElementIsAutofilled(firstname));
-}
-
// If we have multiple labels per id, the labels concatenated into label string.
TEST_F(FormAutofillTest, MultipleLabelsPerElement) {
std::vector<base::string16> labels, names, values;
« no previous file with comments | « no previous file | components/autofill/content/renderer/form_autofill_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698