| Index: third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
|
| diff --git a/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp b/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
|
| index 5da645e13c1e9dabea50501c8cb26d63a4b24206..7e8704b3fc3c64fe23293987007ce7ded97f44d9 100644
|
| --- a/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
|
| +++ b/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
|
| @@ -222,6 +222,20 @@ TEST(PaymentRequestTest, CannotCallShowTwice)
|
| request->show(scope.getScriptState()).then(funcs.expectNoCall(), funcs.expectCall());
|
| }
|
|
|
| +TEST(PaymentRequestTest, CannotShowAfterAborted)
|
| +{
|
| + V8TestingScope scope;
|
| + PaymentRequestMockFunctionScope funcs(scope.getScriptState());
|
| + makePaymentRequestOriginSecure(scope.document());
|
| + PaymentRequest* request = PaymentRequest::create(scope.getScriptState(), buildPaymentMethodDataForTest(), buildPaymentDetailsForTest(), scope.getExceptionState());
|
| + EXPECT_FALSE(scope.getExceptionState().hadException());
|
| + request->show(scope.getScriptState());
|
| + request->abort(scope.getScriptState());
|
| + static_cast<mojom::blink::PaymentRequestClient*>(request)->OnAbort(true);
|
| +
|
| + request->show(scope.getScriptState()).then(funcs.expectNoCall(), funcs.expectCall());
|
| +}
|
| +
|
| TEST(PaymentRequestTest, RejectShowPromiseOnErrorPaymentMethodNotSupported)
|
| {
|
| V8TestingScope scope;
|
|
|