[Snyk] Upgrade @playwright/test from 1.19.0-alpha-1643749494000 to 1.43.1 #1176
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR was automatically created by Snyk using the credentials of a real user.
Snyk has created this PR to upgrade @playwright/test from 1.19.0-alpha-1643749494000 to 1.43.1.
ℹ️ Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.
The recommended version is 1440 versions ahead of your current version.
The recommended version was released a month ago, on 2024-04-12.
The recommended version fixes:
SNYK-JS-SEMVER-3247795
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-BABELTRAVERSE-5962462
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-BRACES-6838727
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-IP-6240864
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-JPEGJS-2859218
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-MICROMATCH-6838728
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-INFLIGHT-6095116
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-JSON5-3182856
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-JSON5-3182856
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-MINIMATCH-3050818
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
SNYK-JS-MINIMIST-2429795
Why? Proof of Concept exploit, Has a fix available, CVSS 7.5
(*) Note that the real score may have changed since the PR was raised.
Release notes
Package name: @playwright/test
Highlights
#30300 - [REGRESSION]: UI mode restarts if keep storage state
#30339 - [REGRESSION]: Brand new install of playwright, unable to run chromium with show browser using vscode
Browser Versions
This version was also tested against the following stable channels:
New APIs
Method browserContext.clearCookies() now supports filters to remove only some cookies.
New mode
retain-on-first-failure
for testOptions.trace. In this mode, trace is recorded for the first run of each test, but not for retires. When test run fails, the trace file is retained, otherwise it is removed.export default defineConfig({
use: {
trace: 'retain-on-first-failure',
},
});
New property testInfo.tags exposes test tags during test execution.
New method locator.contentFrame() converts a
Locator
object to aFrameLocator
. This can be useful when you have aLocator
object obtained somewhere, and later on would like to interact with the content inside the frame.New method frameLocator.owner() converts a
FrameLocator
object to aLocator
. This can be useful when you have aFrameLocator
object obtained somewhere, and later on would like to interact with theiframe
element.UI Mode Updates
@ fast
or clicking on the tag itself.Browser Versions
This version was also tested against the following stable channels:
Highlights
#29732 - [Regression]: HEAD requests to webServer.url since v1.42.0
#29746 - [Regression]: Playwright CT CLI scripts fail due to broken initializePlugin import
#29739 - [Bug]: Component tests fails when imported a module with a dot in a name
#29731 - [Regression]: 1.42.0 breaks some import statements
#29760 - [Bug]: Possible regression with chained locators in v1.42
Browser Versions
This version was also tested against the following stable channels:
New APIs
Test tags
New tag syntax for adding tags to the tests (@-tokens in the test title are still supported).
Use
--grep
command line option to run only tests with certain tags.npx playwright test --grep @ fast
Annotating skipped tests
New annotation syntax for test annotations allows annotating the tests that do not run.
page.addLocatorHandler()
Warning
This feature is experimental, we are actively looking for the feedback based on your scenarios.
New method page.addLocatorHandler() registers a callback that will be invoked when specified element becomes visible and may block Playwright actions. The callback can get rid of the overlay. Here is an example that closes a cookie dialog when it appears.
Project wildcard filter
Playwright command line flag now supports '*' wildcard when filtering by project.
Other APIs
expect(callback).toPass({ timeout })
The timeout can now be configured by
expect.toPass.timeout
option globally or in project configelectronApplication.on('console')
electronApplication.on('console') event is emitted when Electron main process calls console API methods.
page.pdf() accepts two new options
tagged
andoutline
.Breaking changes
Mixing the test instances in the same suite is no longer supported. Allowing it was an oversight as it makes reasoning about the semantics unnecessarily hard.
Announcements
Browser Versions
This version was also tested against the following stable channels:
Highlights
#29123 - [REGRESSION] route.continue: Protocol error (Fetch.continueRequest): Invalid InterceptionId.
Browser Versions
This version was also tested against the following stable channels:
Highlights
#29067 - [REGRESSION] Codegen/Recorder: not all clicks are being actioned nor recorded
#29028 - [REGRESSION] React component tests throw type error when passing null/undefined to component
#29027 - [REGRESSION] React component tests not passing Date prop values
#29023 - [REGRESSION] React component tests not rendering children prop
#29019 - [REGRESSION] trace.playwright.dev does not currently support the loading from URL
Browser Versions
This version was also tested against the following stable channels:
New APIs
style
in page.screenshot([options]) and locator.screenshot([options]) to add custom CSS to the page before taking a screenshot.stylePath
for methods expect(page).toHaveScreenshot(name[, options]) and expect(locator).toHaveScreenshot(name[, options]) to apply a custom stylesheet while making the screenshot.fileName
option for Blob reporter, to specify the name of the report to be created.Browser Versions
This version was also tested against the following stable channels:
Highlights
#28319 - [REGRESSION]: Version 1.40.0 Produces corrupted traces
#28371 - [BUG] The color of the 'ok' text did not change to green in the vs code test results section
#28321 - [BUG] Ambiguous test outcome and status for serial mode
#28362 - [BUG] Merging blobs ends up in Error: Cannot create a string longer than 0x1fffffe8 characters
#28239 - fix: collect all errors in removeFolders
Browser Versions
This version was also tested against the following stable channels:
Test Generator Update
New tools to generate assertions:
Here is an example of a generated test with assertions:
await page.getByRole('link', { name: 'Get started' }).click();
await expect(page.getByLabel('Breadcrumbs').getByRole('list')).toContainText('Installation');
await expect(page.getByLabel('Search')).toBeVisible();
await page.getByLabel('Search').click();
await page.getByPlaceholder('Search docs').fill('locator');
await expect(page.getByPlaceholder('Search docs')).toHaveValue('locator');
});">
New APIs
reason
in page.close(), browserContext.close() and browser.close(). Close reason is reported for all operations interrupted by the closure.firefoxUserPrefs
in browserType.launchPersistentContext(userDataDir).Other Changes
Browser Versions
This version was also tested against the following stable channels: