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

Side by Side Diff: chrome/browser/autofill/select_control_handler_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/stringprintf.h" 5 #include "base/stringprintf.h"
6 #include "base/utf_string_conversions.h" 6 #include "base/utf_string_conversions.h"
7 #include "chrome/browser/autofill/autofill_profile.h" 7 #include "chrome/browser/autofill/autofill_profile.h"
8 #include "chrome/browser/autofill/autofill_type.h" 8 #include "chrome/browser/autofill/autofill_type.h"
9 #include "chrome/browser/autofill/credit_card.h" 9 #include "chrome/browser/autofill/credit_card.h"
10 #include "chrome/browser/autofill/select_control_handler.h" 10 #include "chrome/browser/autofill/select_control_handler.h"
11 #include "chrome/test/testing_browser_process_test.h" 11 #include "chrome/test/base/testing_browser_process_test.h"
12 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
13 #include "webkit/glue/form_field.h" 13 #include "webkit/glue/form_field.h"
14 14
15 typedef TestingBrowserProcessTest SelectControlHandlerTest; 15 typedef TestingBrowserProcessTest SelectControlHandlerTest;
16 16
17 TEST_F(SelectControlHandlerTest, CreditCardMonthExact) { 17 TEST_F(SelectControlHandlerTest, CreditCardMonthExact) {
18 const char* const kMonthsNumeric[] = { 18 const char* const kMonthsNumeric[] = {
19 "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12", 19 "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12",
20 }; 20 };
21 std::vector<string16> options(arraysize(kMonthsNumeric)); 21 std::vector<string16> options(arraysize(kMonthsNumeric));
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 webkit_glue::FormField field; 204 webkit_glue::FormField field;
205 field.form_control_type = ASCIIToUTF16("select-one"); 205 field.form_control_type = ASCIIToUTF16("select-one");
206 field.option_values = values; 206 field.option_values = values;
207 field.option_contents = contents; 207 field.option_contents = contents;
208 208
209 AutofillProfile profile; 209 AutofillProfile profile;
210 profile.SetInfo(ADDRESS_HOME_STATE, ASCIIToUTF16("California")); 210 profile.SetInfo(ADDRESS_HOME_STATE, ASCIIToUTF16("California"));
211 autofill::FillSelectControl(profile, ADDRESS_HOME_STATE, &field); 211 autofill::FillSelectControl(profile, ADDRESS_HOME_STATE, &field);
212 EXPECT_EQ(ASCIIToUTF16("2"), field.value); 212 EXPECT_EQ(ASCIIToUTF16("2"), field.value);
213 } 213 }
OLDNEW
« no previous file with comments | « chrome/browser/autofill/phone_number_i18n_unittest.cc ('k') | chrome/browser/automation/automation_provider_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698