New issue
Advanced search Search tips

Issue 617193 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jun 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 1
Type: Feature

Blocking:
issue 587995



Sign in to add a comment

abort() should return Promise<void>

Project Member Reported by jinho.b...@samsung.com, Jun 3 2016

Issue description

Remove delegated state and make abort() return a promise
 - https://github.com/w3c/browser-payment-api/pull/190
 
Labels: -Pri-2 M-53 Pri-1
Cc: -rouslan@chromium.org jinho.b...@samsung.com
Owner: rouslan@chromium.org
Status: Started (was: Assigned)
Oh, did you already start this work?
Yes, I started it ~15 hours ago :-)
Work in progress @ http://crrev.com/2048823004
Project Member

Comment 6 by bugdroid1@chromium.org, Jun 15 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e411df45423c6c1fd6acb338ce0ea48630784b18

commit e411df45423c6c1fd6acb338ce0ea48630784b18
Author: rouslan <rouslan@chromium.org>
Date: Wed Jun 15 06:48:34 2016

PaymentRequest.abort() should return a promise.

The abort() method on an instance of PaymentRequest returns a promise
that is resolved when the browser has hidden its UI. If the browser is
unable to abort payment, then the abort() promise is rejected. This can
happen, for example, when the browser has launched a 3rd-party payment
app and is unable to abort it.

PaymentRequest interface:
https://w3c.github.io/browser-payment-api/specs/paymentrequest.html#paymentrequest-interface

The abort() method:
https://w3c.github.io/browser-payment-api/specs/paymentrequest.html#abort

The pull request that introduced the promise:
https://github.com/w3c/browser-payment-api/pull/190/files

Additional changes in this patch:
  * Move abort() tests into AbortTest.cpp
  * Move common test fixture into PaymentRequestTestBase.h/cpp.
  * Actually fail tests if MockFunction is not called as expected.
  * Fix RejectShowPromiseWithRequestShippingFalseAndShippingAddressInResponse

BUG= 617193 

Review-Url: https://codereview.chromium.org/2048823004
Cr-Commit-Position: refs/heads/master@{#399854}

[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/BUILD.gn
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/chrome_apk.gyp
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/java/src/org/chromium/chrome/browser/autofill/CardUnmaskBridge.java
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/java/src/org/chromium/chrome/browser/autofill/CardUnmaskPrompt.java
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/java/src/org/chromium/chrome/browser/payments/PaymentRequestImpl.java
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/java/src/org/chromium/chrome/browser/payments/ui/PaymentRequestUI.java
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/java_sources.gni
[add] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/javatests/src/org/chromium/chrome/browser/payments/PaymentRequestAbortTest.java
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/android/javatests/src/org/chromium/chrome/browser/payments/PaymentRequestTestBase.java
[add] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/test/data/android/payments/abort.js
[add] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/chrome/test/data/android/payments/payment_request_abort_test.html
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/LayoutTests/payments/payment-request-interface.html
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/modules.gypi
[add] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/AbortTest.cpp
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/PaymentRequest.h
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/PaymentRequest.idl
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
[add] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/PaymentRequestTestBase.cpp
[add] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/Source/modules/payments/PaymentRequestTestBase.h
[modify] https://crrev.com/e411df45423c6c1fd6acb338ce0ea48630784b18/third_party/WebKit/public/platform/modules/payments/payment_request.mojom

Status: Fixed (was: Started)

Sign in to add a comment