|
|
(17 intermediate revisions by the same user not shown) |
Line 33: |
Line 33: |
| == Edge Cases == | | == Edge Cases == |
|
| |
|
| * Multiple payments chained together | | * First vs. second page of trusted context |
| * Different payment providers (i.e. JWT typ), valid vs. invalid
| | * Multiple JWT requests - same vs. different payment providers |
| * Payment Provider Server Downtime or Failure | | * Web activities firing during trusted UI flow (e.g. phone call) |
| * Invalid JWT requests
| | * No network connection |
| * Switching app contexts post the call of mozPay
| | * Temporary vs. permanent exit of trusted UI context |
| * Interception and altering of content to be rendered within trustworthy UI chrome
| | * Returning to an existing trusted UI context from lockscreen, task switcher, etc |
| * Valid vs. invalid application keys
| | * Trusted UI context in the task manager |
| * Expired vs. Non-Expired Payment Requests and Refunds | | * Canceling purchases |
| * Different country codes
| | * Multiple trusted UI contexts running |
| * Different locale text with JWT request
| | * Exit to task switcher, lockscreen, etc |
| * Optional vs. required parameters for JWT request
| | * Background pages & payments |
| * Default pricing vs. locale-specific pricing
| | * Invalid JWT values for client-side validation |
| * Different country currencies | | * Keyboard use during trusted UI context |
| * Completed vs. Canceled Purchases | |
| * Marketplace Server Downtime or Failure | |
| * Registered application for in-app payments vs. non-registered | |
| * Valid vs. invalid postback and chargeback URLs on successful payments and refunds | |
| * Default price vs. no default price | |
| * Valid vs. invalid amounts | |
| * Application server response vs. invalid response vs. no response on transaction response confirmation | |
| * Successful vs. unsuccessful authentication | |
| * Valid vs. invalid transaction IDs for a refund
| |
| * Masquerading as a valid seller, when in reality the seller is not the one to receive the purchase in app X | |
| * Masquerading as a valid buyer, when in reality the buyer is not the one making the purchase from X account
| |
| * Replaying of in-app purchase requests and refunds multiple times
| |
|
| |
|
| == Signoff Criteria == | | == Signoff Criteria == |
Line 77: |
Line 65: |
| '''Tracking bug:''' [https://bugzilla.mozilla.org/show_bug.cgi?id=777023 bug 777023] | | '''Tracking bug:''' [https://bugzilla.mozilla.org/show_bug.cgi?id=777023 bug 777023] |
|
| |
|
| * Zac Campell is looking into this - primarily aiming to target front-end automation in Marionette in python | | * Zac Campbell is looking into this - primarily aiming to target front-end automation in Marionette in python |
|
| |
|
| == Test Cases and Results == | | == Test Cases == |
|
| |
|
| Brain dump of ideas for test cases is below. Work in progress.
| | Test cases for this feature can be found [https://moztrap.mozilla.org/manage/cases/?filter-suite=183 here]. |
|
| |
|
| * Test that I can make an in-app purchase against the mock payment provider
| | == References == |
| * Test that I can choose and select between two different payments if multiple JWTs are requested
| | |
| * Test that I receive a phone call while I'm in the trusted UI, that I can complete the phone call and return to the trusted UI context | | * [https://docs.google.com/spreadsheet/ccc?key=0AiZoGR-iOAlUdDZFdjREckFkb3dkSWl0Y0lIRmp2d0E#gid=0 Initial Test Pass on 11/9 & 11/12] |
| * Test that I can be notified with a connection failure if there's no connection while I'm in the trusted UI
| |
| * Test that I can leave the trusted UI context back to the homescreen
| |
| * Test that I can return back to an existing trusted UI context by entering an app in that context currently
| |
| * Test that I can see which apps in task manager are in a trusted UI context vs. not
| |
| * Test that I can deny an in-app purchase through the trusted UI context
| |
| * Test that I can run multiple trusted UI contexts across different apps for different payments
| |
| * Test that I can exit to the task switcher while I'm in the trusted UI context
| |
| * Test that I can exit to the lockscreen while I'm in the trusted UI context
| |
| * Test that I can return to a trusted UI context from the lockscreen
| |
| * Test that I can return to a trusted UI context through the task switcher
| |
| * Test that I cannot request a trusted UI context within a background page running
| |
| * Test that I get an error and no trusted UI context when I request an invalid payment provider (aud wrong)
| |
| * Test that I get an error and no trusted UI context when I request an invalid payment provider (typ wrong)
| |
| * Test that I get an error and no trusted UI context when I request an invalid payment provider (typ not specified)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (exp non-numerical)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (iat non-numerical)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (iss non-numerical)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (request not specified)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (name not specified)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (price not specified)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (price not valid)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (invalid currency)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (non-numerical price)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (non-numerical defaultPrice)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (description not specified)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (productdata not a valid URL)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (productdata not a valid URL)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (iat >= exp)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (not valid JSON)
| |
| * Test that I get an error when I request two JWTs with the same payment provider
| |
| * Test that I can make an in-app payment with no iss specified
| |
| * Test that I can make an in-app payment with no iat specified
| |
| * Test that I can make an in-app payment with no exp specified
| |
| * Test that I can make an in-app payment with a single price with no default price specified
| |
| * Test that I can make an in-app payment with UTF-8 characters in the name and description of the request
| |
| * Test that I can make an in-app payment with at least two prices specified in a valid locale
| |
| * Test that I cannot make an in-app payment with a price specified in an unsupported locale
| |
| * Test that I can make an in-app payment with two prices specified with a default price, in which the default price is used due to a locale not specified in prices
| |
| * Test that I can make an in-app payment with two prices specified with a default price, in which the default price is not used due to a locale already specified in prices
| |
| * Test that I can make an in-app payment without productdata, postbackURL, and chargebackURL specified
| |
| * Test that I can make an in-app payment with productdata specified
| |
| * Test that I can make an in-app payment with a postbackURL and chargebackURL that points to a 404
| |
| * Test that I can make an in-app payment with a valid postbackURL and chargebackURL
| |
| * Test that I can make an in-app payment with 10 prices specified with different currencies
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (two currencies that are the same)
| |
| * Test that I get an error and no trusted UI context when I request an invalid JWT (defaultPrice currency not specified in prices)
| |