# `e2e/`

Cross-app Playwright tests + a11y checks via `@axe-core/playwright`.

## Run

```bash
pnpm exec playwright install --with-deps     # first time
pnpm test:e2e
pnpm test:e2e -- --headed                     # watch a real browser
```

## Conventions

- Tests live as `<feature>.spec.ts` at this root for cross-cutting, or under `apps/<app>/e2e/` for app-specific.
- Locale + TZ: `th-TH` + Asia/Bangkok (matches production user).
- `webServer` auto-starts `pnpm dev` locally; CI runs against a pre-built image.
- Every UI test must include an axe-core a11y check; violations are blockers.

## Adding axe-core

```bash
pnpm add -D -w @playwright/test @axe-core/playwright
```

## Failing tests in CI

Artifacts (`playwright-report/`, `test-results/`) upload from the CI job for 7 days. Re-run with `--last-failed` locally to iterate.
