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

Unified Diff: components/autofill/core/browser/autofill_test_utils.cc

Issue 2844463004: Rename card 'type' into 'issuer network.' (Closed)
Patch Set: read -> use Created 3 years, 8 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: components/autofill/core/browser/autofill_test_utils.cc
diff --git a/components/autofill/core/browser/autofill_test_utils.cc b/components/autofill/core/browser/autofill_test_utils.cc
index 10a23dcb2c605ed7540089141768db7e217f39c9..991b907bcc0bc1d4813c66657a0499c663167e4b 100644
--- a/components/autofill/core/browser/autofill_test_utils.cc
+++ b/components/autofill/core/browser/autofill_test_utils.cc
@@ -254,7 +254,7 @@ CreditCard GetMaskedServerCard() {
CreditCard credit_card(CreditCard::MASKED_SERVER_CARD, "a123");
test::SetCreditCardInfo(&credit_card, "Bonnie Parker",
"2109" /* Mastercard */, "12", "2020");
- credit_card.SetTypeForMaskedCard(kMasterCard);
+ credit_card.SetNetworkForMaskedCard(kMasterCard);
return credit_card;
}
@@ -262,7 +262,7 @@ CreditCard GetMaskedServerCardAmex() {
CreditCard credit_card(CreditCard::MASKED_SERVER_CARD, "b456");
test::SetCreditCardInfo(&credit_card, "Justin Thyme",
"8431" /* Amex */, "9", "2020");
- credit_card.SetTypeForMaskedCard(kAmericanExpressCard);
+ credit_card.SetNetworkForMaskedCard(kAmericanExpressCard);
return credit_card;
}
@@ -322,9 +322,8 @@ void SetServerCreditCards(AutofillTable* table,
std::vector<CreditCard> as_masked_cards = cards;
for (CreditCard& card : as_masked_cards) {
card.set_record_type(CreditCard::MASKED_SERVER_CARD);
- std::string type = card.type();
card.SetNumber(card.LastFourDigits());
- card.SetTypeForMaskedCard(type.c_str());
+ card.SetNetworkForMaskedCard(card.network());
}
table->SetServerCreditCards(as_masked_cards);
« no previous file with comments | « components/autofill/core/browser/autofill_sync_constants.cc ('k') | components/autofill/core/browser/credit_card.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698