Testing payments
Confirm a payment without a frontend
Section titled “Confirm a payment without a frontend”After creating a payment intent, confirm it with the Stripe CLI:
stripe payment_intents confirm <pi_...> \ --payment-method pm_card_visa \ --return-url "https://example.com/done"With stripe listen running, the resulting webhook updates the local payment.
Test payment methods
Section titled “Test payment methods”| Payment method | Result |
|---|---|
pm_card_visa |
Succeeds |
pm_card_chargeDeclined |
Declines |
Running the service’s tests
Section titled “Running the service’s tests”npm test # unit testsnpm run build # production build