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

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

Issue 11635039: [Autofill] Update unit tests to use country codes when setting raw address info. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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/autofill_manager_unittest.cc
diff --git a/chrome/browser/autofill/autofill_manager_unittest.cc b/chrome/browser/autofill/autofill_manager_unittest.cc
index ff0126f3b7a93946e5e9f3186c0546c1382457a4..7f98b25491f98ca16001d2bfffaf556ba94cebc0 100644
--- a/chrome/browser/autofill/autofill_manager_unittest.cc
+++ b/chrome/browser/autofill/autofill_manager_unittest.cc
@@ -159,7 +159,7 @@ class TestPersonalDataManager : public PersonalDataManager {
autofill_test::SetProfileInfo(profile, "Elvis", "Aaron",
"Presley", "theking@gmail.com", "RCA",
"3734 Elvis Presley Blvd.", "Apt. 10",
- "Memphis", "Tennessee", "38116", "USA",
+ "Memphis", "Tennessee", "38116", "US",
"12345678901");
profile->set_guid("00000000-0000-0000-0000-000000000001");
profiles->push_back(profile);
@@ -167,7 +167,7 @@ class TestPersonalDataManager : public PersonalDataManager {
autofill_test::SetProfileInfo(profile, "Charles", "Hardin",
"Holley", "buddy@gmail.com", "Decca",
"123 Apple St.", "unit 6", "Lubbock",
- "Texas", "79401", "USA", "23456789012");
+ "Texas", "79401", "US", "23456789012");
profile->set_guid("00000000-0000-0000-0000-000000000002");
profiles->push_back(profile);
profile = new AutofillProfile;
@@ -2476,8 +2476,7 @@ TEST_F(AutofillManagerTest, FillPhoneNumber) {
// We should not be able to fill prefix and suffix fields for international
// numbers.
- work_profile->SetRawInfo(ADDRESS_HOME_COUNTRY,
- ASCIIToUTF16("United Kingdom"));
+ work_profile->SetRawInfo(ADDRESS_HOME_COUNTRY, ASCIIToUTF16("GB"));
work_profile->SetRawInfo(PHONE_HOME_WHOLE_NUMBER,
ASCIIToUTF16("447700954321"));
page_id = 3;
@@ -2516,7 +2515,7 @@ TEST_F(AutofillManagerTest, FillPhoneNumber) {
std::vector<string16> phone_variants;
phone_variants.push_back(ASCIIToUTF16("16505554567"));
phone_variants.push_back(ASCIIToUTF16("18887771234"));
- work_profile->SetRawInfo(ADDRESS_HOME_COUNTRY, ASCIIToUTF16("United States"));
+ work_profile->SetRawInfo(ADDRESS_HOME_COUNTRY, ASCIIToUTF16("US"));
work_profile->SetRawMultiInfo(PHONE_HOME_WHOLE_NUMBER, phone_variants);
page_id = 5;
« no previous file with comments | « chrome/browser/autofill/autofill_browsertest.cc ('k') | chrome/browser/autofill/autofill_metrics_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698