← All articles
QA · 10 min read

E-commerce QA: how we test the path to payment

Every checkout bug costs real money. Our checklist covers the order flow, money rules, payments with 3-D Secure, race conditions and load before big sales.

In an online store most bugs are annoying, but bugs between “Add to cart” and “Order confirmed” cost revenue directly. That is why our e-commerce test strategy is built around the money path, and why it gets the most automation and the most careful regression before every release.

ProductCartShippingPaymentConfirmation!!!Red markers: where most revenue-losing bugs appearThe money path

1. Cart and order flow

  • Add, remove, change quantity; quantity 0, negative, above stock, very large numbers
  • Cart persistence: after login, logout, in another browser, after 30 days
  • Guest checkout vs. registered user; switching between them in the middle
  • Back button, refresh and opening checkout in two tabs
  • Address validation: postcodes, apartment numbers, Cyrillic and other non-Latin input, very long street names

2. Money rules

Discounts, taxes and currencies are where boundary values and decision tables pay off most. A typical promo setup quickly produces dozens of combinations.

ScenarioWhy it breaks
Order total exactly at the free-shipping threshold> vs >= in the rule
Promo code on its expiry day, in another time zoneServer and user time differ
Two discounts that must not stackMissing exclusion rule
Percentage discount on a 0.99 itemRounding to cents
Currency switch after a coupon is appliedDiscount not recalculated
Refund of one item from a discounted orderDiscount distributed incorrectly

3. Payments

We test payments in the provider's sandbox with its official test cards, never with real ones. The minimum scenario set:

  1. Successful payment
  2. Card declined (insufficient funds, expired card, wrong CVC)
  3. 3-D Secure challenge passed, failed and abandoned
  4. User closes the tab during redirect to the bank
  5. Payment succeeds at the provider but the webhook arrives late or twice
  6. Refund, partial refund and chargeback flows
  7. Alternative methods: Apple Pay, Google Pay, PayPal, bank transfer, cash on delivery
Scenario 5 is the one most often missed and most expensive in production: the customer is charged but the order stays “pending”, or two orders are created. Every payment webhook handler must be idempotent.

4. Race conditions and stock

  • Two customers buy the last item at the same moment
  • Double-click on “Pay” creates two orders
  • The price changes while the customer is on the checkout page
  • An item goes out of stock between cart and payment

These are hard to catch manually, so we combine scripted concurrency tests at API level with targeted exploratory sessions.

5. Notifications and after-sale

Order confirmation emails and SMS, correct language and currency in them, invoices, tracking links, account order history, and the full return flow. Customers judge the store by these as much as by the site itself.

6. Performance before peaks

Black Friday or a big campaign can multiply traffic many times over. Before a sale we run load tests on the critical journey (browse → product → cart → checkout) with realistic data, watch response times at the 95th percentile, error rate and database load, and agree on a degradation plan: what can be switched off if the site slows down.

7. What we automate

LayerWhatTool examples
APICart, prices, discounts, order state machinePostman/Newman, REST Assured, pytest
UI end-to-end5–10 critical journeys incl. payment in sandboxPlaywright, Cypress
LoadBrowse, search, checkout under peak traffick6, JMeter
MonitoringSynthetic checkout every few minutes in productionUptime and synthetic tools

Everything else — new promo mechanics, UX, content — is covered by exploratory testing before each release, guided by the risk of the change.