MockingCrow adds a test gateway to WooCommerce, so you can run the whole checkout without a real payment provider, an API key or a sandbox account.
After placing an order, the customer is taken to a hosted test payment page. The page shows the order summary, and the customer chooses the outcome:
- Approve: the order is marked paid (Processing or Completed) and the customer sees the order received page.
- Decline: the order is marked Failed and the customer sees WooCommerce’s “payment failed” page, with a Pay button to try again.
- Cancel and return to store: the order is cancelled and the customer goes back to the cart.
Why I built this
I build WooCommerce stores and plugins, and every project hits the same wall: to test anything that happens after checkout, you need an order that has actually been paid.
The usual options all slow you down:
- A real gateway’s sandbox needs an account, API keys and webhooks that can reach your machine. That is hard on
localhost, and every developer on the team has to set it up.
- Cash on delivery or bank transfer never marks an order as paid, so the order stays On hold and nothing that depends on payment runs.
- Changing order statuses by hand in the admin skips the code paths a real payment goes through, so bugs in those paths stay hidden.
I wanted a gateway that behaves like a real hosted payment page: the customer leaves the checkout, decides what happens, and comes back. Then WooCommerce does exactly what it would do with a real payment. No account, no keys, no internet connection needed. MockingCrow is that gateway.
Why test with a mock gateway
The checkout is where a store makes its money, and it is also the part that is hardest to test. A mock gateway lets you test the whole order flow, from cart to “Thank you” page, as many times as you need, for free.
- Real order lifecycle. Approving calls WooCommerce’s own
payment_complete(), so stock is reduced, the order moves to Processing or Completed, the customer and admin emails are sent, and every hook that listens for a paid order runs, such as woocommerce_payment_complete and woocommerce_order_status_processing.
- Failure paths too. Most bugs hide in the unhappy path. Decline an order to see the “payment failed” page, the failed-order email and the Pay again flow. Cancel to test what happens when a customer walks away.
- Repeatable. Every test order goes through the same steps, so you can reproduce a bug, fix it and check the fix in a couple of minutes.
- Safe. No card numbers, no real customer data and no money ever leave your site.
- Works offline. Everything runs on your own server, so it works on
localhost, inside Docker, on a plane, or on a staging site behind a password.
Who it is for
- Store builders checking a new theme, checkout layout or Thank you page before launch.
- Plugin developers testing code that runs when orders are paid, failed, cancelled or refunded, such as memberships, digital downloads, licence keys, CRM or ERP sync, and fulfilment integrations.
- Email designers who need to trigger real WooCommerce order emails.
- QA teams and automated tests (Playwright, Cypress and similar) that need a checkout which completes without a third-party iframe. The payment page uses plain HTML forms with stable labels, so it is easy to script.
- Agencies and freelancers showing clients the complete buying journey on a demo or staging site.
- Teachers and students learning how WooCommerce orders work.
Example workflows
Test a new theme before launch
- Activate MockingCrow on your staging site and turn on Admins only.
- Place an order and approve it. Check the Thank you page and the emails.
- Place another order and decline it. Check the failed page, then pay again from the link.
- Refund the paid order from the order screen and check the refund email.
Test a plugin that runs on paid orders
- Place an order with MockingCrow and approve it.
- Check that your plugin did its job, for example granted access, sent data to an API or created a licence.
- Place another order and decline it. Make sure your plugin did nothing.
Features
- Works with the Checkout block and the classic
[woocommerce_checkout] shortcode.
- Compatible with High-Performance Order Storage (HPOS).
- Uses WooCommerce’s own order functions, so orders behave exactly like real paid, failed or cancelled orders.
- Each approved payment gets a unique transaction ID that starts with
MOCK-, so test orders are easy to recognise.
- Refunds from the order screen always succeed, and each one is logged as an order note.
- An “Admins only” option hides the gateway from everyone except shop managers and administrators.
- The payment page shows the store name, icon, items and totals, and works on phones.
- The payment page is a template that you can override in your theme.
- Protected against tampering: each payment page link needs the order’s secret key, and each choice is checked with a WordPress nonce.
- Translation ready.
- No external requests, no tracking, no ads and no upsells. No data leaves your site.
Warning: never use on a live store
Anyone who picks Approve gets their order without paying. MockingCrow is a development and testing tool only.
- On a local site, use it freely.
- On a staging or demo site that others can reach, turn on Admins only in WooCommerce > Settings > Payments > MockingCrow.
- Before launch, deactivate and delete the plugin, then enable your real payment gateway.
Privacy
MockingCrow does not collect, store or send any personal data. It makes no external HTTP requests and sets no cookies. The only thing it saves is its own settings, which are removed when you delete the plugin.