Skip to content

Playwright

Playwright can repeat a customer’s journey through your web app and check whether it worked. Keep the test with your app and run it after changes.

Visit Playwright

What can Playwright check for you?

Playwright can book a test slot, reopen the app and check that the same appointment is still there. It can repeat that journey on different browser engines.

Playwright Test runs scripts that interact with your web app. The setup here uses JavaScript or TypeScript for the test files. The app itself can use another language. The test uses the browser to follow the steps and fails at the first expected result it cannot find.

Choose the smallest customer journey that would hurt to break. Checking only that the page shows a confirmation can miss a failed save. Reopen the booking and check the customer-facing record as part of the same test.

How do you turn clicks into a check that can fail?

Record the journey to get a first draft, then make the test say what should be true after the last click.

  1. Set up a copy you can change
    Run the app with separate test sign-in settings and a test database. Use a fake account and slot. Turn off payments and reminders or direct them to test systems you control.
  2. Record the customer’s actions
    Use Playwright’s generator to open the booking page, choose the slot and submit it. Save the generated script in your project so you can read and edit it.
  3. Check the saved outcome
    Start a fresh browser session, sign in as the same fake account and check that exactly one booking shows the chosen time. Put the unavailable-slot case in its own test, with a predictable starting record.
  4. Make the test prove itself
    On the disposable copy, try an intentional failure such as showing confirmation without saving. The reopened-booking check should fail. Restore the save and rerun it.

Which browsers and phones does Playwright cover?

The local runner can use Chromium, Firefox and WebKit. These are browser engines, the parts that turn a web page’s code into what you see. A phone profile changes settings such as screen size and touch. For branded Safari on an actual iPhone, check on that device.

Choose the run that matches your question
What you want to learnWhat to run
Will this flow work on more than one browser engine?Run the same journey in Chromium, Firefox and WebKit. Add a supported Chrome or Edge channel if you need that branded desktop browser.
Does the layout fit a phone-sized screen?Use a device profile for repeatable checks of width and touch behavior. Keep the browser and screen settings consistent for image comparisons.
Is the form usable with a real mobile browser and keyboard?Use the actual phone and browser. Record the device and where you got stuck.

How do you find the first thing that went wrong?

Open the failed check first. If you recorded a trace, it can show the browser actions and what the page looked like at each step.

If the booking was never reopened, look at the action that failed to get there. If the page reopened but the record was missing, check the test slot and save flow before rewriting the test. A trace can help explain both cases.

Set your automatic runner to keep useful traces from failed runs. Traces can include page snapshots, requests and logs. Saved sign-in state can contain information that lets another person act as the test account. Keep both out of a public repository and keep access and retention limited.

What do you pay for, and what stays with the app?

Playwright Test is open source under Apache 2.0 and has no runner subscription fee. A machine that runs the tests, storage for their files or a hosted device service can have its own cost.

Keep the test files, configuration and instructions for preparing fake records with the project. With those pieces, a teammate can run the same check on their computer or your automatic runner. Keep credentials and signed-in session files separately.