TestopiusTestopius
2026-10-08·7 min read

Silent e-commerce bugs: coupons, returns and stock that go wrong

Checkout gets all the attention while discounts, returns and inventory quietly lose money. The failures we look for in these three areas and the checks that catch them.

e-commercecouponsinventorybugs

Teams test the checkout button carefully, because it is obvious. The bugs that cost the most are often elsewhere, in areas that work in the demo and fail with real combinations of customers, discounts and stock.

We cover the payment step itself in 5 checkout checks before launch. Here are the three neighbouring areas that quietly leak money.

Coupons and discounts

Discount logic looks simple until two rules meet.

  • Stacking. Apply two coupons, or a coupon on top of a sale price. Does the total go lower than intended, even below zero?
  • Minimums and limits. A coupon for orders above a threshold: does it still apply after an item is removed from the cart?
  • Expiry and usage caps. Try an expired coupon, and one that should only work once per customer. Use it twice.
  • Percentage on mixed carts. Check that a discount applies only to eligible products and rounds correctly.
  • Free shipping thresholds. Test just below, exactly at and just above the limit.

Quick check: build a cart worth exactly the minimum, apply the coupon, then change the quantity so the cart drops below it. The discount should disappear.

Returns and refunds

Returns are rarely tested because they happen after the sale, yet they involve money going out.

  • Partial refunds. Return one item from an order of three. Does the refund include the right share of discount and shipping?
  • Refund to the right place. Confirm the amount goes back through the original payment method.
  • Stock after a return. Does the item return to inventory, and only when it should?
  • Status and emails. Order status, confirmation emails and the customer's account should all agree.
  • Repeat actions. Click refund twice. You should never refund the same item twice.

Stock and inventory

Stock bugs create the worst customer experience: you take payment for something you do not have.

  • The last item. Two customers buy the last unit at the same moment. Only one should succeed, clearly.
  • Stock in the cart. What happens when an item sells out while it sits in someone's cart?
  • Variants. Sizes and colours must each track their own stock.
  • Back in stock and out of stock labels should update promptly and consistently across list and product pages.
  • Cancelled orders. Stock should be released when an order is cancelled or a payment fails.

Why these bugs stay hidden

They depend on combinations and timing: two customers, two discounts, a return weeks later. Single-path demos never hit them, and automated happy-path tests rarely cover them. They show up as slightly wrong totals and unhappy customers, not error messages.

Where to start

Write a short table of your discount rules, your return rules and your stock rules, then create one test case for every rule and every pair of rules that can meet. That list alone finds bugs.

Launching a shop?

Our E-commerce Launch QA covers checkout, payments, discounts and inventory testing. See the e-commerce launch QA page or get a quote.

Frequently asked questions

Why are discount bugs so common?
Because rules interact. Each rule works alone, but combinations such as stacked coupons, partial returns and thresholds create cases nobody designed or tested.
How do we test the last-item race condition?
Use two sessions, ideally automated, to purchase the final unit at nearly the same moment. Confirm only one order succeeds and the other customer receives a clear message.
Do returns really need test coverage?
Yes. Money goes out, stock changes and customers are watching. A wrong refund or a stock count that drifts is expensive to discover in production.

Need this done for you?

We test web, mobile, and desktop apps for startups. Fixed prices, fast turnaround.

See packages
Author

Testopius

QA engineer with 7+ years testing web, mobile, and desktop products. We deliver fixed-price, fixed-timeline manual audits and Playwright automation for startups and small teams.

Related posts