Closed renovate[bot] closed 2 years ago
Latest commit: 1ae4c954381de024cc329ce70b70736972cf8a0c
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
This PR contains the following updates:
^1.17.1
->^1.19.2
Release Notes
Microsoft/playwright
### [`v1.19.2`](https://togithub.com/Microsoft/playwright/releases/v1.19.2) [Compare Source](https://togithub.com/Microsoft/playwright/compare/v1.19.1...v1.19.2) #### Highlights This patch includes the following bug fixes: [https://github.com/microsoft/playwright/issues/12091](https://togithub.com/microsoft/playwright/issues/12091) - \[BUG] playwright 1.19.0 generates more than 1 trace file per test[https://github.com/microsoft/playwright/issues/12106](https://togithub.com/microsoft/playwright/issues/12106)6 - \[BUG] Error: EBUSY: resource busy or locked when using volumes in docker-compose with playwright 1.19.0 and mcr.microsoft.com/playwright:v1.15.0-focal #### Browser Versions - Chromium 100.0.4863.0 - Mozilla Firefox 96.0.1 - WebKit 15.4 This version was also tested against the following stable channels: - Google Chrome 98 - Microsoft Edge 98 ### [`v1.19.1`](https://togithub.com/Microsoft/playwright/releases/v1.19.1) [Compare Source](https://togithub.com/Microsoft/playwright/compare/v1.19.0...v1.19.1) ##### Highlights This patch includes the following bug fixes: [https://github.com/microsoft/playwright/issues/12075](https://togithub.com/microsoft/playwright/issues/12075) - \[Question] After update to 1.19 firefox fails to run[https://github.com/microsoft/playwright/issues/12090](https://togithub.com/microsoft/playwright/issues/12090)0 - \[BUG] did something change on APIRequest/Response APIs ? ##### Browser Versions - Chromium 100.0.4863.0 - Mozilla Firefox 96.0.1 - WebKit 15.4 This version was also tested against the following stable channels: - Google Chrome 98 - Microsoft Edge 98 ### [`v1.19.0`](https://togithub.com/Microsoft/playwright/releases/v1.19.0) [Compare Source](https://togithub.com/Microsoft/playwright/compare/v1.18.1...v1.19.0) #### Version 1.19 ##### Playwright Test Updates ##### Soft assertions Playwright Test v1.19 now supports **soft assertions**. Failed soft assertions **do not** terminate test execution, but mark the test as failed. Read more in [our documentation](https://playwright.dev/docs/test-assertions#soft-assertions). ```js // Make a few checks that will not stop the test when failed... await expect.soft(page.locator('#status')).toHaveText('Success'); await expect.soft(page.locator('#eta')).toHaveText('1 day'); // ... and continue the test to check more things. await page.locator('#next-page').click(); await expect.soft(page.locator('#title')).toHaveText('Make another order'); ``` ##### Custom error messages You can now specify a [**custom error message**](https://playwright.dev/docs/test-assertions#custom-error-message) as a second argument to the `expect` and `expect.soft` functions, for example: ```js await expect(page.locator('text=Name'), 'should be logged in').toBeVisible(); ``` The error would look like this: ```bash Error: should be logged in Call log: - expect.toBeVisible with timeout 5000ms - waiting for selector "text=Name" 2 | 3 | test('example test', async({ page }) => { > 4 | await expect(page.locator('text=Name'), 'should be logged in').toBeVisible(); | ^ 5 | }); 6 | ``` ##### Parallel mode in file 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 [`method: test.describe.configure`](https://playwright.dev/docs/api/class-test#test-describe-configure): ```js import { test } from '@playwright/test'; test.describe.configure({ mode: 'parallel' }); test('parallel 1', async () => {}); test('parallel 2', async () => {}); ``` ##### [ā ļø](https://emojipedia.org/warning/#:~:text=A%20triangle%20with%20an%20exclamation,to%20Emoji%201.0%20in%202015.) Potentially breaking change in Playwright Test Global Setup It is unlikely that this change will affect you, no action is required if your tests keep running as they did. We've noticed that in rare cases, the set of tests to be executed was configured in the global setup by means of the environment variables. We also noticed some applications that were post processing the reporters' output in the global teardown. If you are doing one of the two, [learn more](https://togithub.com/microsoft/playwright/issues/12018) ##### Locator Updates ##### Locator now supports a `has` option that makes sure it contains another locator inside: ```js await page.locator('article', { has: page.locator('.highlight'), }).locator('button').click(); ``` The snippet above will select article that has highlight in it and will press the button in it. Read more in [locator documentation](https://playwright.dev/docs/api/class-locator#locator-locator-option-has) ##### Other Updates - New [`method: Locator.page`](https://playwright.dev/docs/api/class-locator#locator-page) - [`method: Page.screenshot`](https://playwright.dev/docs/api/class-page#page-screenshot) and [`method: Locator.screenshot`](https://playwright.dev/docs/api/class-locator#locator-screenshot) now automatically hides blinking caret - Playwright Codegen now generates locators and frame locators - New option `url` in [`testConfig.webServer`](https://playwright.dev/docs/api/class-testconfig#test-config-web-server) to ensure your web server is ready before running the tests - New [`property: TestInfo.errors`](https://playwright.dev/docs/api/class-testinfo#test-info-errors) and [`property: TestResult.errors`](https://playwright.dev/docs/api/class-testresult#test-result-errors) that contain all failed assertions and soft assertions. #### Browser Versions - Chromium 100.0.4863.0 - Mozilla Firefox 96.0.1 - WebKit 15.4 This version was also tested against the following stable channels: - Google Chrome 98 - Microsoft Edge 98 *** ### [`v1.18.1`](https://togithub.com/Microsoft/playwright/releases/v1.18.1) [Compare Source](https://togithub.com/Microsoft/playwright/compare/v1.18.0...v1.18.1) ##### Highlights This patch includes improvements to the TypeScript support and the following bug fixes: [https://github.com/microsoft/playwright/issues/11550](https://togithub.com/microsoft/playwright/issues/11550) - \[REGRESSION]: Errors inside route handler does not lead to unhandled rejections anymore[https://github.com/microsoft/playwright/issues/11552](https://togithub.com/microsoft/playwright/issues/11552)2 - \[BUG] Could not resolve "C:\repo\framework\utils" in file C:\repo\tests\test.ts. ##### Browser Versions - Chromium 99.0.4812.0 - Mozilla Firefox 95.0 - WebKit 15.4 This version was also tested against the following stable channels: - Google Chrome 97 - Microsoft Edge 97 ### [`v1.18.0`](https://togithub.com/Microsoft/playwright/releases/v1.18.0) [Compare Source](https://togithub.com/Microsoft/playwright/compare/v1.17.2...v1.18.0) #### Locator Improvements - [`locator.dragTo(locator)`][locator.dragTo(locator)] - [`expect(locator).toBeChecked({ checked })`][expect(locator).toBeChecked({ checked })] - Each locator can now be optionally filtered by the text it contains: ```js await page.locator('li', { hasText: 'my item' }).locator('button').click(); ``` Read more in [locator documentation]. #### Testing API improvements - [`expect(response).toBeOK()`][expect(response).toBeOK()] - [`testInfo.attach()`][testInfo.attach()] - [`test.info()`][test.info()] #### Improved TypeScript Support 1. Playwright Test now respects `tsconfig.json`'s [`baseUrl`](https://www.typescriptlang.org/tsconfig#baseUrl) and [`paths`](https://www.typescriptlang.org/tsconfig#paths), so you can use aliases 2. There is a new environment variable `PW_EXPERIMENTAL_TS_ESM` that allows importing ESM modules in your TS code, without the need for the compile step. Don't forget the `.js` suffix when you are importing your esm modules. Run your tests as follows: ```bash npm i --save-dev @playwright/test@1.18.0 PW_EXPERIMENTAL_TS_ESM=1 npx playwright test ``` #### Create Playwright The `npm init playwright` command is now generally available for your use: ```sh ### Run from your project's root directory npm init playwright ### Or create a new project npm init playwright new-project ``` This will scaffold everything needed to get started with Playwright Test: configuration file, optionally add examples, a GitHub Action workflow and a first test `example.spec.ts`. #### New APIs & changes - new [`testCase.repeatEachIndex`][testCase.repeatEachIndex] API - [`acceptDownloads`][acceptDownloads] option now defaults to `true` #### Breaking change: custom config options Custom config options are a convenient way to parametrize projects with different values. Learn more in the [parametrization guide]. Previously, any fixture introduced through [`test.extend`][test.extend] could be overridden in the [`testProject.use`][testProject.use] config section. For example, ```js // WRONG: THIS SNIPPET DOES NOT WORK SINCE v1.18. // fixtures.js const test = base.extend({ myParameter: 'default', }); // playwright.config.js module.exports = { use: { myParameter: 'value', }, }; ``` The proper way to make a fixture parametrized in the config file is to specify `option: true` when defining the fixture. For example, ```js // CORRECT: THIS SNIPPET WORKS SINCE v1.18. // fixtures.js const test = base.extend({ // Fixtures marked as "option: true" will get a value specified in the config, // or fallback to the default value. myParameter: ['default', { option: true }], }); // playwright.config.js module.exports = { use: { myParameter: 'value', }, }; ``` #### Browser Versions - Chromium 99.0.4812.0 - Mozilla Firefox 95.0 - WebKit 15.4 This version was also tested against the following stable channels: - Google Chrome 97 - Microsoft Edge 97 *** [`locator.dragTo(locator)`]: https://playwright.dev/docs/api/class-locator#locator-drag-to [`expect(locator).toBeChecked({ checked })`]: https://playwright.dev/docs/api/class-locatorassertions#locator-assertions-to-be-checked [locator documentation]: https://playwright.dev/docs/api/class-locator#locator-locator-option-has-text [`expect(response).toBeOK()`]: https://playwright.dev/docs/api/class-apiresponseassertions [`testInfo.attach()`]: https://playwright.dev/docs/api/class-testinfo#test-info-attach [`test.info()`]: https://playwright.dev/docs/api/class-test#test-info [`testCase.repeatEachIndex`]: https://playwright.dev/docs/api/class-testcase#test-case-repeat-each-index [parametrization guide]: https://playwright.dev/docs/test-parameterize#parameterized-projects [`acceptDownloads`]: https://playwright.dev/docs/api/class-browser#browser-new-context-option-accept-downloads [`test.extend`]: https://playwright.dev/docs/api/class-test#test-extend [`testProject.use`]: https://playwright.dev/docs/api/class-testproject#test-project-use (`1.18.0-beta-1642620709000`) ### [`v1.17.2`](https://togithub.com/Microsoft/playwright/releases/v1.17.2) [Compare Source](https://togithub.com/Microsoft/playwright/compare/v1.17.1...v1.17.2) ##### Bugfixes [#11274](https://togithub.com/Microsoft/playwright/issues/11274) - fix: pin colors to 1.4.0 [#11228](https://togithub.com/Microsoft/playwright/issues/11228) - fix(click): don't fail on stale context while clickConfiguration
š Schedule: At any time (no schedule defined).
š¦ Automerge: Disabled by config. Please merge this manually once you are satisfied.
ā» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
š Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by WhiteSource Renovate. View repository job log here.