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

Unified Diff: chrome/browser/autocomplete_history_manager_unittest.cc

Issue 2853027: Don't save SSNs. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 10 years, 6 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
« no previous file with comments | « chrome/browser/autocomplete_history_manager.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autocomplete_history_manager_unittest.cc
===================================================================
--- chrome/browser/autocomplete_history_manager_unittest.cc (revision 51464)
+++ chrome/browser/autocomplete_history_manager_unittest.cc (working copy)
@@ -84,3 +84,22 @@
EXPECT_CALL(*(web_data_service_.get()), AddFormFields(_)).Times(1);
autocomplete_manager_->FormSubmitted(form);
}
+
+// Tests that SSNs are not sent to the WebDatabase to be saved.
+TEST_F(AutocompleteHistoryManagerTest, SSNValue) {
+ FormData form;
+ form.name = ASCIIToUTF16("MyForm");
+ form.method = ASCIIToUTF16("POST");
+ form.origin = GURL("http://myform.com/form.html");
+ form.action = GURL("http://myform.com/submit.html");
+
+ webkit_glue::FormField ssn(ASCIIToUTF16("Social Security Number"),
+ ASCIIToUTF16("ssn"),
+ ASCIIToUTF16("078-05-1120"),
+ ASCIIToUTF16("text"),
+ 20);
+ form.fields.push_back(ssn);
+
+ EXPECT_CALL(*web_data_service_, AddFormFields(_)).Times(0);
+ autocomplete_manager_->FormSubmitted(form);
+}
« no previous file with comments | « chrome/browser/autocomplete_history_manager.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698