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

Side by Side Diff: components/autofill/core/browser/personal_data_manager_unittest.cc

Issue 2819183004: [Autofill] Change MasterCard to Mastercard in UI and related tests (Closed)
Patch Set: Resolved conflict Created 3 years, 7 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "components/autofill/core/browser/personal_data_manager.h" 5 #include "components/autofill/core/browser/personal_data_manager.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <list> 10 #include <list>
(...skipping 3853 matching lines...) Expand 10 before | Expand all | Expand 10 after
3864 3864
3865 suggestions = personal_data_->GetCreditCardSuggestions( 3865 suggestions = personal_data_->GetCreditCardSuggestions(
3866 AutofillType(CREDIT_CARD_NUMBER), /* field_contents= */ base::string16()); 3866 AutofillType(CREDIT_CARD_NUMBER), /* field_contents= */ base::string16());
3867 ASSERT_EQ(4U, suggestions.size()); 3867 ASSERT_EQ(4U, suggestions.size());
3868 EXPECT_EQ( 3868 EXPECT_EQ(
3869 base::UTF8ToUTF16(std::string("Visa") + kUTF8MidlineEllipsis + "9012"), 3869 base::UTF8ToUTF16(std::string("Visa") + kUTF8MidlineEllipsis + "9012"),
3870 suggestions[0].value); 3870 suggestions[0].value);
3871 EXPECT_EQ( 3871 EXPECT_EQ(
3872 base::UTF8ToUTF16(std::string("Amex") + kUTF8MidlineEllipsis + "8555"), 3872 base::UTF8ToUTF16(std::string("Amex") + kUTF8MidlineEllipsis + "8555"),
3873 suggestions[1].value); 3873 suggestions[1].value);
3874 EXPECT_EQ(base::UTF8ToUTF16(std::string("MasterCard") + kUTF8MidlineEllipsis + 3874 EXPECT_EQ(base::UTF8ToUTF16(std::string("Mastercard") + kUTF8MidlineEllipsis +
3875 "2109"), 3875 "2109"),
3876 suggestions[2].value); 3876 suggestions[2].value);
3877 EXPECT_EQ( 3877 EXPECT_EQ(
3878 base::UTF8ToUTF16(std::string("Visa") + kUTF8MidlineEllipsis + "2109"), 3878 base::UTF8ToUTF16(std::string("Visa") + kUTF8MidlineEllipsis + "2109"),
3879 suggestions[3].value); 3879 suggestions[3].value);
3880 } 3880 }
3881 3881
3882 // Tests that a full server card can be a dupe of more than one local card. 3882 // Tests that a full server card can be a dupe of more than one local card.
3883 TEST_F(PersonalDataManagerTest, 3883 TEST_F(PersonalDataManagerTest,
3884 GetCreditCardSuggestions_ServerCardDuplicateOfMultipleLocalCards) { 3884 GetCreditCardSuggestions_ServerCardDuplicateOfMultipleLocalCards) {
(...skipping 2617 matching lines...) Expand 10 before | Expand all | Expand 10 after
6502 EXPECT_EQ("", card->billing_address_id()); 6502 EXPECT_EQ("", card->billing_address_id());
6503 } else { 6503 } else {
6504 // The billing address of local_card1 and server_card1 should still refer 6504 // The billing address of local_card1 and server_card1 should still refer
6505 // to profile1. 6505 // to profile1.
6506 EXPECT_EQ(profile1.guid(), card->billing_address_id()); 6506 EXPECT_EQ(profile1.guid(), card->billing_address_id());
6507 } 6507 }
6508 } 6508 }
6509 } 6509 }
6510 6510
6511 } // namespace autofill 6511 } // namespace autofill
OLDNEW
« no previous file with comments | « components/autofill/core/browser/credit_card_unittest.cc ('k') | components/autofill_strings.grdp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698