v1.54.0
Breaking Changes📦 playwrightView on GitHub →
⚠ 3 breaking✨ 4 features⚡ 1 deprecations🔧 7 symbols
Summary
This release adds partitioned cookie support, new reporting options, and a CLI flag for user data directories, while removing the `-gv` flag, changing the behavior of `playwright open`, and dropping Node.js 16 support.
⚠️ Breaking Changes
- `-gv` option removed from `npx playwright test`; use `--grep-invert` instead.
- `npx playwright open` no longer opens the test recorder; use `npx playwright codegen` to launch the recorder.
- Support for Node.js 16 has been removed; projects running on Node 16 must upgrade to a newer Node version.
Migration Steps
- Replace any usage of `-gv` with `--grep-invert` in test command scripts.
- If you relied on `npx playwright open` to launch the test recorder, switch to `npx playwright codegen`.
- Upgrade the runtime to Node.js 18 or newer (preferably Node.js 20) since Node.js 16 is no longer supported.
- Update any code that parses cookie objects to handle the new `partitionKey` field if needed.
✨ New Features
- Added `partitionKey` property to `browserContext.cookies()` and `browserContext.addCookies()` for partitioned cookies.
- Introduced `noSnippets` option to disable code snippets in the HTML report.
- Added `location` property to test annotations (`testResult.annotations` and `testInfo.annotations`).
- Added `--user-data-dir` CLI option to reuse browsing state across sessions.
🔧 Affected Symbols
browserContext.cookiesbrowserContext.addCookiestestResult.annotationstestInfo.annotationsnpx playwright test (CLI option -gv)npx playwright opennode runtime version⚡ Deprecations
- Support for Node.js 18 is deprecated and will be removed in a future release.