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

Side by Side Diff: components/autofill/browser/wallet/wallet_items_unittest.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/json/json_reader.h" 5 #include "base/json/json_reader.h"
6 #include "base/logging.h" 6 #include "base/logging.h"
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "components/autofill/browser/wallet/required_action.h" 10 #include "components/autofill/browser/wallet/required_action.h"
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after
411 TEST_F(WalletItemsTest, CreateMaskedInstrument) { 411 TEST_F(WalletItemsTest, CreateMaskedInstrument) {
412 SetUpDictionary(kMaskedInstrument); 412 SetUpDictionary(kMaskedInstrument);
413 scoped_ptr<Address> address(new Address("country_code", 413 scoped_ptr<Address> address(new Address("country_code",
414 ASCIIToUTF16("name"), 414 ASCIIToUTF16("name"),
415 ASCIIToUTF16("address1"), 415 ASCIIToUTF16("address1"),
416 ASCIIToUTF16("address2"), 416 ASCIIToUTF16("address2"),
417 ASCIIToUTF16("city"), 417 ASCIIToUTF16("city"),
418 ASCIIToUTF16("state"), 418 ASCIIToUTF16("state"),
419 ASCIIToUTF16("postal_code"), 419 ASCIIToUTF16("postal_code"),
420 ASCIIToUTF16("phone_number"), 420 ASCIIToUTF16("phone_number"),
421 "")); 421 std::string()));
422 std::vector<string16> supported_currencies; 422 std::vector<string16> supported_currencies;
423 supported_currencies.push_back(ASCIIToUTF16("currency")); 423 supported_currencies.push_back(ASCIIToUTF16("currency"));
424 WalletItems::MaskedInstrument masked_instrument( 424 WalletItems::MaskedInstrument masked_instrument(
425 ASCIIToUTF16("descriptive_name"), 425 ASCIIToUTF16("descriptive_name"),
426 WalletItems::MaskedInstrument::VISA, 426 WalletItems::MaskedInstrument::VISA,
427 supported_currencies, 427 supported_currencies,
428 ASCIIToUTF16("last_four_digits"), 428 ASCIIToUTF16("last_four_digits"),
429 12, 429 12,
430 2012, 430 2012,
431 address.Pass(), 431 address.Pass(),
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
513 "obfuscated_gaia_id"); 513 "obfuscated_gaia_id");
514 514
515 scoped_ptr<Address> billing_address(new Address("country_code", 515 scoped_ptr<Address> billing_address(new Address("country_code",
516 ASCIIToUTF16("name"), 516 ASCIIToUTF16("name"),
517 ASCIIToUTF16("address1"), 517 ASCIIToUTF16("address1"),
518 ASCIIToUTF16("address2"), 518 ASCIIToUTF16("address2"),
519 ASCIIToUTF16("city"), 519 ASCIIToUTF16("city"),
520 ASCIIToUTF16("state"), 520 ASCIIToUTF16("state"),
521 ASCIIToUTF16("postal_code"), 521 ASCIIToUTF16("postal_code"),
522 ASCIIToUTF16("phone_number"), 522 ASCIIToUTF16("phone_number"),
523 "")); 523 std::string()));
524 std::vector<string16> supported_currencies; 524 std::vector<string16> supported_currencies;
525 supported_currencies.push_back(ASCIIToUTF16("currency")); 525 supported_currencies.push_back(ASCIIToUTF16("currency"));
526 scoped_ptr<WalletItems::MaskedInstrument> masked_instrument( 526 scoped_ptr<WalletItems::MaskedInstrument> masked_instrument(
527 new WalletItems::MaskedInstrument(ASCIIToUTF16("descriptive_name"), 527 new WalletItems::MaskedInstrument(ASCIIToUTF16("descriptive_name"),
528 WalletItems::MaskedInstrument::VISA, 528 WalletItems::MaskedInstrument::VISA,
529 supported_currencies, 529 supported_currencies,
530 ASCIIToUTF16("last_four_digits"), 530 ASCIIToUTF16("last_four_digits"),
531 12, 531 12,
532 2012, 532 2012,
533 billing_address.Pass(), 533 billing_address.Pass(),
(...skipping 23 matching lines...) Expand all
557 ASCIIToUTF16("display_name"))); 557 ASCIIToUTF16("display_name")));
558 expected.AddLegalDocument(legal_document.Pass()); 558 expected.AddLegalDocument(legal_document.Pass());
559 expected.AddLegalDocument( 559 expected.AddLegalDocument(
560 WalletItems::LegalDocument::CreatePrivacyPolicyDocument()); 560 WalletItems::LegalDocument::CreatePrivacyPolicyDocument());
561 561
562 EXPECT_EQ(expected, *WalletItems::CreateWalletItems(*dict)); 562 EXPECT_EQ(expected, *WalletItems::CreateWalletItems(*dict));
563 } 563 }
564 564
565 } // namespace wallet 565 } // namespace wallet
566 } // namespace autofill 566 } // namespace autofill
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698