woocommerce-paypal-payments/tests/playwright
2023-05-30 11:46:25 +03:00
..
utils Handle random popup issues in pw 2023-05-30 11:46:25 +03:00
.gitignore Move playwright ignores to its own directory 2023-02-24 15:55:04 +01:00
place-order.spec.js Extract pw common functions 2023-05-29 09:47:42 +03:00
README.md Update readme 2023-03-22 11:39:19 +02:00
subscriptions-api.spec.js Fix pw order completion check 2023-05-29 17:14:27 +03:00

Playwright Testing

Set Environment Variables

Duplicate .env.e2e.example and rename it to .env.e2e, set the values needed for the tests, like account credentials, card numbers.

Install Playwright dependencies (browsers)

$ yarn ddev:pw-install

Run Tests

$ yarn ddev:pw-tests

You can also choose which tests to run filtering by name

$ yarn ddev:pw-tests --grep "Test name or part of the name"

Or run without the headless mode (show the browser)

$ yarn pw-tests-headed

Or run with the test debugger

$ yarn playwright test --debug

For the headed/debug mode (currently works only outside DDEV) you may need to re-install the deps if you are not on Linux.

$ yarn pw-install

See Playwright docs for more info.