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

Unified Diff: chrome/browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc

Issue 2896263002: [Payments] Changes to validation in the Credit Card editor (Closed)
Patch Set: rebase 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc
diff --git a/chrome/browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc b/chrome/browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc
index f5decea0d8410b86c4726e075940573286bec00e..4b8edd22de409bf01e37a1f29903844611d7eb16 100644
--- a/chrome/browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc
+++ b/chrome/browser/ui/views/payments/shipping_address_editor_view_controller_browsertest.cc
@@ -551,7 +551,7 @@ IN_PROC_BROWSER_TEST_F(PaymentRequestShippingAddressEditorTest,
}
IN_PROC_BROWSER_TEST_F(PaymentRequestShippingAddressEditorTest,
- FocusFirstInvalidField_Name) {
+ FocusFirstField_Name) {
InvokePaymentRequestUI();
SetRegionDataLoader(&test_region_data_loader_);
@@ -564,13 +564,14 @@ IN_PROC_BROWSER_TEST_F(PaymentRequestShippingAddressEditorTest,
EditorViewController::GetInputFieldViewId(autofill::NAME_FULL)));
DCHECK(textfield);
EXPECT_TRUE(textfield->text().empty());
- EXPECT_TRUE(textfield->invalid());
+ // Field is not invalid because there is nothing in it.
+ EXPECT_FALSE(textfield->invalid());
EXPECT_TRUE(textfield->HasFocus());
}
IN_PROC_BROWSER_TEST_F(PaymentRequestShippingAddressEditorTest,
FocusFirstInvalidField_NotName) {
- // Add address with the name set, so that another view takes focus.
+ // Add address with only the name set, so that another view takes focus.
autofill::AutofillProfile profile;
profile.SetInfo(autofill::AutofillType(autofill::NAME_FULL),
base::ASCIIToUTF16(kNameFull), "fr_CA");

Powered by Google App Engine
This is Rietveld 408576698