cypress
16.3.0 · 10 Nov 2026MIT7.6M / weekRepositoryHomepagenpmAtom feed
Upgrading cypress From 16.1.1 to 16.2.0
1 release in betweenevery note read
Reading releases, release notes and advisories…
Security
- 16.2.0
Upgraded
shell-quotefrom1.10.0to1.11.0to address a Command Injection vulnerability reported in security scans.shell-quoteis a transitive dependency oflaunch-editor. Addressed in #34960.
Release by release
- Security
Upgraded
shell-quotefrom1.10.0to1.11.0to address a Command Injection vulnerability reported in security scans.shell-quoteis a transitive dependency oflaunch-editor. Addressed in #34960. - New
Added the cy.getByRole() query, which finds elements by their ARIA role and, optionally, their accessible name, for example
cy.getByRole('tab', { name: 'Billing' }). Elements hidden from the accessibility tree are skipped unless you pass{ hidden: true }. For a role that HTML has an element for, only that element matches by default, socy.getByRole('button')finds a<button>but not a<div role="button">. Pass{ native: false }to also match elements with aroleattribute. Like cy.get(), it yields every match and retries until its assertions pass. When nothing matches, the error lists the roles and accessible names on the page. Addressed in #34937. - Fixed
Fixed a regression in 16.0.0 where a configured clientCertificates entry was not presented for requests the browser issued in Chrome, Chromium, and Edge, so an origin requiring mutual TLS showed a certificate prompt in
cypress openand hung incypress run. Fixes #34807. - Fixed
Fixed a regression in 15.20.0 where a cookie changed by cy.request() or cy.setCookie() was sent to the server with its earlier value on the next navigation of the application under test, even though cy.getCookie() reported the new one. Fixes #34891.
- Security
4 other lines we could not sort, mostly version bumps
- 16.2.0
cy.get() now fails right away when you ask for index
0of a cy.intercept() alias, such ascy.get('@getUsers.0'). Previously, Cypress retried until the command timed out before it showed the error, even though retrying could never succeed. Fixed in #34936. - 16.2.0
Calling a query that needs a subject, such as .eq(), .first(), .find(), or .shadow(), directly off
cyinstead of chaining it off a command that yields a subject now fails right away with an error that names the command and explains that it must be chained. Previously, Cypress retried until the command timed out and then reported that the subject was not a DOM element, or, when the query was the first command in a test, failed withCannot read properties of undefined (reading 'get'). Child commands called directly offcy, such ascy.click(), show the same reworded error. Fixed in #35024. - 16.2.0
TypeScript now types the object yielded by cy.location() as the plain object Cypress actually yields, instead of the browser's
window.location.searchParamsis now typed, socy.location('searchParams')andloc.searchParams.get('q')no longer report a type error. Addressed in #34956. - 16.2.0
Masked the environment variable values on the Project settings page. Addressed in #35004.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.