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

Side by Side Diff: chrome/browser/autofill/credit_card_unittest.cc

Issue 7616019: Reorganize chrome/test, part #9 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 4 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/utf_string_conversions.h" 6 #include "base/utf_string_conversions.h"
7 #include "chrome/browser/autofill/autofill_common_test.h" 7 #include "chrome/browser/autofill/autofill_common_test.h"
8 #include "chrome/browser/autofill/credit_card.h" 8 #include "chrome/browser/autofill/credit_card.h"
9 #include "chrome/test/testing_browser_process_test.h" 9 #include "chrome/test/base/testing_browser_process_test.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
11 11
12 namespace { 12 namespace {
13 13
14 // From https://www.paypalobjects.com/en_US/vhelp/paypalmanager_help/credit_card _numbers.htm 14 // From https://www.paypalobjects.com/en_US/vhelp/paypalmanager_help/credit_card _numbers.htm
15 const char* const kValidNumbers[] = { 15 const char* const kValidNumbers[] = {
16 "378282246310005", 16 "378282246310005",
17 "3714 4963 5398 431", 17 "3714 4963 5398 431",
18 "3787-3449-3671-000", 18 "3787-3449-3671-000",
19 "5610591081018250", 19 "5610591081018250",
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 174
175 card.SetInfo(CREDIT_CARD_EXP_MONTH, ASCIIToUTF16("7")); 175 card.SetInfo(CREDIT_CARD_EXP_MONTH, ASCIIToUTF16("7"));
176 EXPECT_EQ(ASCIIToUTF16("07"), card.GetInfo(CREDIT_CARD_EXP_MONTH)); 176 EXPECT_EQ(ASCIIToUTF16("07"), card.GetInfo(CREDIT_CARD_EXP_MONTH));
177 177
178 card.SetInfo(CREDIT_CARD_EXP_MONTH, ASCIIToUTF16("January")); 178 card.SetInfo(CREDIT_CARD_EXP_MONTH, ASCIIToUTF16("January"));
179 EXPECT_EQ(ASCIIToUTF16("01"), card.GetInfo(CREDIT_CARD_EXP_MONTH)); 179 EXPECT_EQ(ASCIIToUTF16("01"), card.GetInfo(CREDIT_CARD_EXP_MONTH));
180 180
181 card.SetInfo(CREDIT_CARD_EXP_MONTH, ASCIIToUTF16("Apr")); 181 card.SetInfo(CREDIT_CARD_EXP_MONTH, ASCIIToUTF16("Apr"));
182 EXPECT_EQ(ASCIIToUTF16("04"), card.GetInfo(CREDIT_CARD_EXP_MONTH)); 182 EXPECT_EQ(ASCIIToUTF16("04"), card.GetInfo(CREDIT_CARD_EXP_MONTH));
183 } 183 }
OLDNEW
« no previous file with comments | « chrome/browser/autofill/autofill_profile_unittest.cc ('k') | chrome/browser/autofill/personal_data_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698