feca-mailshots-plugin/tests/e2e/README.md

35 lines
993 B
Markdown

# Browser E2E (Playwright)
This suite runs browser-based smoke/regression coverage against fixture-hosted admin UI (`tests/fixture/wp-admin/*`).
## Run
```bash
tests/e2e/run.sh
```
Or manually:
```bash
scripts/run_fixture_server.sh start
npm install
npx playwright install chromium
E2E_BASE_URL=http://127.0.0.1:8080 npx playwright test
```
## Specs
- `admin-ui-smoke.spec.mjs`
- page-load smoke for Data Sources, Mailshots, Attachments, PDF Assets.
- `data-sources.spec.mjs`
- modal create flow, preview regression guard (`contacts and accounts`), validation failure path.
- `mailshots-editor.spec.mjs`
- datasource-driven token/field population, message/PDF overlay editor flows, create mailshot.
- `run-test-pages.spec.mjs`
- Run/Test page load checks and API failure-path assertions (`run_mailshot` invalid id, `send_test` blank email).
## Notes
- Tests clean up created Data Source/Mailshot artefacts.
- This suite is intended as a pre-manual gate before release/deploy.