blob: 58883acfd5a3eb12b4ef36cf471dab0de3322f63 [file] [log] [blame]
This is a testharness.js-based test.
FAIL Calling show() without being triggered by user interaction throws promise_rejects_dom: function "function() { throw e }" threw object "UnknownError: Renderer process could not establish or lost IPC connection to the PaymentRequest service in the browser process." that is not a DOMException NotAllowedError: property "name" is equal to "UnknownError", expected "NotAllowedError"
FAIL Throws if the promise [[state]] is not 'created'. promise_rejects_dom: function "function() { throw e }" threw object "InvalidStateError: Failed to execute 'show' on 'PaymentRequest': Already called show() once" that is not a DOMException NotAllowedError: property "code" is equal to 11, expected 0
FAIL If the user agent's "payment request is showing" boolean is true, then return a promise rejected with an "AbortError" DOMException. promise_rejects_dom: function "function() { throw e }" threw object "InvalidStateError: Failed to execute 'show' on 'PaymentRequest': Already called show() once" that is not a DOMException NotAllowedError: property "code" is equal to 11, expected 0
FAIL If payment method consultation produces no supported method of payment, then return a promise rejected with a "NotSupportedError" DOMException. promise_rejects_dom: function "function() { throw e }" threw object "InvalidStateError: Failed to execute 'show' on 'PaymentRequest': Already called show() once" that is not a DOMException NotSupportedError: property "code" is equal to 11, expected 9
FAIL Calling show() multiple times always returns a new promise. promise_test: Unhandled rejection with value: object "InvalidStateError: Failed to execute 'abort' on 'PaymentRequest': No show() or retry() in progress, so nothing to abort"
Harness: the test ran to completion.