Index: chrome/browser/ui/views/payments/shipping_option_view_controller_browsertest.cc |
diff --git a/chrome/browser/ui/views/payments/shipping_option_view_controller_browsertest.cc b/chrome/browser/ui/views/payments/shipping_option_view_controller_browsertest.cc |
index f5fe1dc08dc825c791fec174be5c9d7bb4645614..9e73b878021fdb8f71218e8e0bd91ab55692c4a9 100644 |
--- a/chrome/browser/ui/views/payments/shipping_option_view_controller_browsertest.cc |
+++ b/chrome/browser/ui/views/payments/shipping_option_view_controller_browsertest.cc |
@@ -26,7 +26,7 @@ class PaymentRequestShippingOptionViewControllerTest |
}; |
IN_PROC_BROWSER_TEST_F(PaymentRequestShippingOptionViewControllerTest, |
- OrderSummaryReflectsShippingOption) { |
+ SelectingVariousShippingOptions) { |
// In MI state, shipping is $5.00. |
autofill::AutofillProfile michigan = autofill::test::GetFullProfile2(); |
michigan.set_use_count(100U); |
@@ -80,6 +80,18 @@ IN_PROC_BROWSER_TEST_F(PaymentRequestShippingOptionViewControllerTest, |
// available for Canada. |
EXPECT_EQ(nullptr, dialog_view()->GetViewByID(static_cast<int>( |
DialogViewID::PAYMENT_SHEET_SHIPPING_OPTION_SECTION))); |
+ |
+ // There is now an appropriate error that is shown in the shipping address |
+ // section of the Payment Sheet. The string is returned by the merchant. |
+ EXPECT_EQ(base::ASCIIToUTF16("We do not ship to this address"), |
+ GetProfileLabelValues( |
+ DialogViewID::PAYMENT_SHEET_SHIPPING_ADDRESS_SECTION) |
+ .back()); |
+ |
+ // Go to the address selector and see this error as well. |
+ OpenShippingAddressSectionScreen(); |
+ EXPECT_EQ(base::ASCIIToUTF16("We do not ship to this address"), |
+ GetLabelText(DialogViewID::SHIPPING_ADDRESS_OPTION_ERROR)); |
} |
} // namespace payments |