Testing
Produce every outcome on the test Wall: a purchase, a decline, a renewal that fails, a refund, a dispute, a refused build.
Everything on the test Wall runs against Stripe's test mode. Nothing is charged, and every outcome a buyer can meet can be produced with a test card or from the dashboard.
Before you begin
- A tool wired to the test Wall, with a plan under Pricing. See Quickstart.
- For webhooks: an endpoint, or
npx -y toolaby@latest webhooks trigger. See Webhooks. - For several test buyers from one inbox,
+tagaddresses:you+1@gmail.com,you+2@gmail.com. Dots in a Gmail address are the same buyer.
Cards
On Stripe's checkout page, any future expiry date and any CVC.
| Card | Outcome |
|---|---|
4242 4242 4242 4242 | Paid. |
4000 0000 0000 0002 | Declined. Stripe shows the decline; nothing is recorded. |
4000 0025 0000 3155 | Requires 3D Secure authentication first. |
4000 0000 0000 0341 | Attaches to the customer, then fails when charged: a subscription's first payment fails. |
4000 0000 0000 0259 | Paid, then disputed: payment.disputed follows within minutes. |
4000 0000 0000 9995 | Insufficient funds. |
Stripe's full list is at docs.stripe.com/testing.
Scenarios
| To see | Do |
|---|---|
| A purchase | Buy from the popup with 4242…. The popup unlocks; the customer appears; purchase.completed is sent. |
| A subscription with a trial | Set a free trial on the subscription plan under Pricing, subscribe. Stripe's page says n days free; user.subscription.status is trialing. |
| A failed renewal | Subscribe with 4000 0000 0000 0341. The first payment fails; the subscription is not active, so gate() refuses. |
| A cancellation | From the buyer's account page (Stripe's portal), or from the customer's page with Cancel. subscription.cancelled is sent. |
| A plan switch | From the buyer's account page, Change plan. The row updates within seconds. |
| A refund | Refund on the customer's page. The licence is revoked; the extension stops at its next check; payment.refunded is sent. |
| A dispute | Pay with 4000 0000 0000 0259. The licence shows as disputed; payment.disputed is sent. Stripe's test disputes close by themselves as won after a while. |
| A refused build | Under Versions, set a minimum version above the extension's. The Wall popup shows your message at its next open. Without an open, gate() refuses within the hour. |
| The Free plan's limit | Set the Free plan to a number of uses, use them up. The paywall appears with the plans. |
| A second device | Load the extension in a second Chrome profile and sign in. The account page lists both. A third beyond Devices per licence is refused. |
| A grant | Grant access on the Customers page, or POST /grants. The extension unlocks at its next check. |
| Another language or currency | See Buyer pages. |
Webhooks without a purchase
npx -y toolaby@latest webhooks trigger payment.refunded --to http://localhost:4000/webhooksSends the event's example, signed, to a server on your machine. See Webhooks.
Resetting
There is no reset. Delete the test tool under its Settings, or refund and revoke from the Customers page. Buyers on the test Wall are separate from live and are never copied there.