BLOG
BlogGuides

Check the record was saved, not just the success message

A thank-you message proves the page changed, not that anything was stored. Check the record on screen, or read your system through an endpoint you define.

A message is not a result#

A form says "Thanks, we got it". An order page says "Order confirmed". A settings page flashes "Saved". Each message is a promise the front end makes, and front ends make it whether or not the server stored anything.

The gap shows up in support forums in both directions. One form builder's users found submissions saved to the database but no email sent; a WooCommerce store owner saw failed, cancelled and duplicate orders after updates, behind a checkout that still looked fine. And apps built quickly often show the success state before the request has even finished.

There are two good ways to check the record behind the message.

1. Check it where a user would see it#

Most of the time the record shows somewhere in the app: an orders list, a profile page, a dashboard. Check there, after a reload:

Submit the contact form with the subject "TEST order 1182".
Check the page says the message was sent.
Sign in to the admin as the account "admin" and open Messages.
Check a message with the subject "TEST order 1182" is listed.

This needs nothing but a stored sign-in account for the admin side, and it is the right first test for nearly every form. Saved, then gone after a refresh has more of these.

2. Ask your system directly#

Some records never show on a screen: a webhook received, a row in a reporting table, a lead pushed to your CRM. For those, give the tester an endpoint: a call into your own system that you define, such as lookup_order, with a description of when to use it (how endpoints work).

  • You set the method, the https address and the headers. Headers (your token) are encrypted and never shown to the tester; it sees only the endpoint's name and description, and after a call the status and the response.
  • The tester fills in the parameters you allow, for example the order number it read on the confirmation page.
Place an order for "Blue mug" with the test card.
Note the order number on the confirmation page.
Use lookup_order with that order number.
Check the response says the status is "paid" and the item is
"Blue mug".

The check then rests on what your system says, not on what the page claimed. Endpoint calls are on paid plans; a run can make up to 40 mailbox, phone and endpoint calls.

The same mechanism sets things up and cleans up: create_voucher before a checkout test, delete_test_user at the end (keeping production data clean).

Which to use#

Start with the screen: it is what users see and it needs no code. Add an endpoint where the screen cannot tell you, or where the screen is the thing you do not trust. We have not published a run with an endpoint yet; the fields and limits above are from our docs.

This post is part of Release testing for product teams.

Filed underWebForms and checkoutCI, schedules and agents