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.
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?
How do we test the last-item race condition?
Do returns really need test coverage?
Need this done for you?
We test web, mobile, and desktop apps for startups. Fixed prices, fast turnaround.
See packagesRelated posts
5 checkout checks that catch payment-flow bugs before launch
A practical QA checklist for totals, payment retries, provider states, stock changes, and redirect returns—with a mini bug hunt you can try.
7 silent payment flow bugs we've found before fintech launches
The bugs that pass code review, pass QA, and still cost fintechs five figures within a week of launch. Each with the test case that would have caught it.