[macOS Debug WK2] Layout Test http/tests/ssl/applepay/ApplePayShippingAddressChangeEv...
authoraestes@apple.com <aestes@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 24 Oct 2018 14:15:15 +0000 (14:15 +0000)
committeraestes@apple.com <aestes@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 24 Oct 2018 14:15:15 +0000 (14:15 +0000)
commitc75011c55b9b52aae42362e030c2267cef4fee25
tree281611b4927eeca75fa0a48da98f9938723965d7
parent98fbe15e334a15b79f95812a2f651711367c3d98
[macOS Debug WK2] Layout Test http/tests/ssl/applepay/ApplePayShippingAddressChangeEventErrorsV3.https.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=190650
<rdar://problem/45341914>

Reviewed by Alex Christensen.

Source/WebCore:

In computeErrors, we intend to ignore errors when computing paymentMethodErrors. But we
weren't clearing exceptions generated from calling convert(), so they would end up being
logged as unhandled promise rejections.

Changed ApplePayPaymentHandler::computeErrors() to use a CatchScope to clear exceptions when
decoding paymentMethodErrors.

Also changed ApplePayShippingAddressChangeEventErrorsV3.https.html to catch promise
rejections from calling PaymentRequest.abort().

Covered by existing test.

* Modules/applepay/paymentrequest/ApplePayPaymentHandler.cpp:
(WebCore::ApplePayPaymentHandler::computeErrors const):

LayoutTests:

* http/tests/resources/payment-request.js:
(updateDetailsOnShippingAddressChange):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@237381 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/http/tests/resources/payment-request.js
Source/WebCore/ChangeLog
Source/WebCore/Modules/applepay/paymentrequest/ApplePayPaymentHandler.cpp