Changeset 56926 for trunk/tests/e2e/README.md
- Timestamp:
- 10/13/2023 08:11:41 AM (12 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/e2e/README.md
r51904 r56926 6 6 ## Running the tests 7 7 8 The e2e tests require a production-like environment to run. By default, they will assume an environment is available at `http://localhost:8889`, with username =admin and password=password.8 The e2e tests require a production-like environment to run. By default, they will assume an environment is available at `http://localhost:8889`, with username `admin` and password `password`. 9 9 10 10 If you don't already have an environment ready, you can set one up by following [these instructions](https://github.com/WordPress/wordpress-develop/blob/master/README.md). … … 21 21 22 22 ``` 23 npm run test:e2e -- --wordpress-base-url=http://mycustomurl --wordpress-username=username --wordpress-password=password 23 WP_BASE_URL=http://mycustomurl WP_USERNAME=username WP_PASSWORD=password npm run test:e2e 24 24 ``` 25 25 **DO NOT run these tests in an actual production environment, as they will delete all your content.** 26 26 27 For debugging purposes, you might want to follow the test visually. You can do so by running the tests in an interactive mode .27 For debugging purposes, you might want to follow the test visually. You can do so by running the tests in an interactive mode: 28 28 29 29 ``` 30 npm run test:e2e -- -- puppeteer-interactive30 npm run test:e2e -- --ui 31 31 ``` 32 33 [UI Mode](https://playwright.dev/docs/test-ui-mode) let's you explore, run and debug tests with a time travel experience complete with watch mode. 34 All test files are loaded into the testing sidebar where you can expand each file and describe block to individually run, view, watch and debug each test. 32 35 33 36 You can also run a single test file separately: … … 42 45 * Block Editor Handbook end to end testing overview: https://developer.wordpress.org/block-editor/contributors/code/testing-overview/#end-to-end-testing 43 46 44 * Gutenberg e2e-test-utils package API docs: https://github.com/WordPress/gutenberg/tree/trunk/packages/e2e-test-utils47 * Gutenberg e2e-test-utils-playwright package API docs: https://github.com/WordPress/gutenberg/tree/trunk/packages/e2e-test-utils-playwright 45 48 46 * P uppeteer API docs: https://github.com/puppeteer/puppeteer#readme (the version we are using is indicated in the @wordpress/scriptspackage: https://github.com/WordPress/gutenberg/blob/trunk/packages/scripts/package.json)49 * Playwright API docs: https://playwright.dev/docs (the version we are using is indicated in the `@wordpress/scripts` package: https://github.com/WordPress/gutenberg/blob/trunk/packages/scripts/package.json)
Note: See TracChangeset
for help on using the changeset viewer.