v1.15.0
π Playwright Library
π±οΈ Mouse Wheel
By using Page.mouse.wheel
you are now able to scroll vertically or horizontally.
π New Headers API
Previously it was not possible to get multiple header values of a response. This is now possible and additional helper functions are available:
- Request.allHeaders()
- Request.headersArray()
- Request.headerValue(name: string)
- Response.allHeaders()
- Response.headersArray()
- Response.headerValue(name: string)
- Response.headerValues(name: string)
π Forced-Colors emulation
Its now possible to emulate the forced-colors
CSS media feature by passing it in the context options or calling Page.emulateMedia().
New APIs
- Page.route() accepts new
times
option to specify how many times this route should be matched. - Page.setChecked(selector: string, checked: boolean) and Locator.setChecked(selector: string, checked: boolean) was introduced to set the checked state of a checkbox.
- Request.sizes() Returns resource size information for given http request.
- BrowserContext.tracing.startChunk() - Start a new trace chunk.
- BrowserContext.tracing.stopChunk() - Stops a new trace chunk.
π Playwright Test
π€ test.parallel()
run tests in the same file in parallel
test.describe.parallel('group', () => {
test('runs in parallel 1', async ({ page }) => {
});
test('runs in parallel 2', async ({ page }) => {
});
});
By default, tests in a single file are run in order. If you have many independent tests in a single file, you can now run them in parallel with test.describe.parallel(title, callback).
π Add --debug
CLI flag
By using npx playwright test --debug
it will enable the Playwright Inspector for you to debug your tests.
Browser Versions
- Chromium 96.0.4641.0
- Mozilla Firefox 92.0
- WebKit 15.0
This version of Playwright was also tested against the following stable channels:
- Google Chrome 93
- Microsoft Edge 93