Skip to content

chore: merge develop into cypress release 15 branch #31464

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Apr 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
4ed0186
dependency: upgrade mocha to 7.2.0 (#31423)
jennifer-shehane Apr 2, 2025
30dadab
chore: updating v8 snapshot cache (#31424)
github-actions[bot] Apr 2, 2025
be5fba4
chore: updating v8 snapshot cache (#31425)
github-actions[bot] Apr 2, 2025
ef6b2e8
chore: updating v8 snapshot cache (#31426)
github-actions[bot] Apr 2, 2025
f4bf384
chore: migrates plugin system test to a v3 extension (#31434)
cacieprins Apr 2, 2025
17e2a26
chore: Update Chrome (stable) to 135.0.7049.52 (#31428)
github-actions[bot] Apr 2, 2025
6868b0a
chore: bump Firefox to 137 (#31431)
jennifer-shehane Apr 2, 2025
ec53844
dependency: update server to mocha 7.2.0 (#31432)
jennifer-shehane Apr 2, 2025
70fe91a
chore: updating v8 snapshot cache (#31437)
github-actions[bot] Apr 3, 2025
e63504e
chore: updating v8 snapshot cache (#31438)
github-actions[bot] Apr 3, 2025
355b521
chore: updating v8 snapshot cache (#31439)
github-actions[bot] Apr 3, 2025
bd67278
chore: Update Chrome (beta) to 136.0.7103.17 (#31448)
github-actions[bot] Apr 4, 2025
6bf7383
refactor: lifts toPosix to its own file, removes circular dependency …
cacieprins Apr 4, 2025
108eb7e
internal: (studio) make the protocol database accessible to studio (#…
ryanthemanuel Apr 6, 2025
920128a
chore(deps): update dependency patch-package to v8 (#31451)
renovate[bot] Apr 7, 2025
d691e19
chore: fix deprecation warnings and refactor react reporter to use fu…
AtofStryker Apr 7, 2025
f16ff6c
chore: update snap-shot-core patch package file to match version (#31…
jennifer-shehane Apr 7, 2025
0412642
chore: updating v8 snapshot cache (#31460)
github-actions[bot] Apr 8, 2025
34ced95
chore: updating v8 snapshot cache (#31462)
github-actions[bot] Apr 8, 2025
9155e05
chore: updating v8 snapshot cache (#31461)
github-actions[bot] Apr 8, 2025
cfdeb7a
feat: cy.press() (#31398)
cacieprins Apr 8, 2025
1bd9768
docs: update contributing requirements for corepack (#31463)
MikeMcC399 Apr 8, 2025
9a30e6b
chore: remove `du` check (#31465)
cacieprins Apr 8, 2025
83e0d3c
chore: release 14.3.0 (#31467)
AtofStryker Apr 8, 2025
5876a8f
Merge branch 'develop' of github.com:cypress-io/cypress into merge_de…
AtofStryker Apr 8, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/cache-version.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Bump this version to force CI to re-create the cache from scratch.

3-18-2024:4:25
4-7-2025-v1
24 changes: 13 additions & 11 deletions .circleci/workflows.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
version: 2.1

chrome-stable-version: &chrome-stable-version "134.0.6998.165"
chrome-beta-version: &chrome-beta-version "135.0.7049.41"
firefox-stable-version: &firefox-stable-version "136.0.3"
chrome-stable-version: &chrome-stable-version "135.0.7049.52"
chrome-beta-version: &chrome-beta-version "136.0.7103.17"
firefox-stable-version: &firefox-stable-version "137.0"

orbs:
browser-tools: circleci/[email protected]
Expand Down Expand Up @@ -38,7 +38,7 @@ mainBuildFilters: &mainBuildFilters
- /^release\/\d+\.\d+\.\d+$/
# use the following branch as well to ensure that v8 snapshot cache updates are fully tested
- 'update-v8-snapshot-cache-on-develop'
- 'renovate/webdriverio-monorepo'
- 'chore/fix_react_18_deprecation_warnings'

# usually we don't build Mac app - it takes a long time
# but sometimes we want to really confirm we are doing the right thing
Expand All @@ -49,7 +49,7 @@ macWorkflowFilters: &darwin-workflow-filters
- equal: [ develop, << pipeline.git.branch >> ]
# use the following branch as well to ensure that v8 snapshot cache updates are fully tested
- equal: [ 'update-v8-snapshot-cache-on-develop', << pipeline.git.branch >> ]
- equal: [ 'renovate/webdriverio-monorepo', << pipeline.git.branch >> ]
- equal: [ 'chore/fix_react_18_deprecation_warnings', << pipeline.git.branch >> ]
- matches:
pattern: /^release\/\d+\.\d+\.\d+$/
value: << pipeline.git.branch >>
Expand All @@ -60,7 +60,7 @@ linuxArm64WorkflowFilters: &linux-arm64-workflow-filters
- equal: [ develop, << pipeline.git.branch >> ]
# use the following branch as well to ensure that v8 snapshot cache updates are fully tested
- equal: [ 'update-v8-snapshot-cache-on-develop', << pipeline.git.branch >> ]
- equal: [ 'renovate/webdriverio-monorepo', << pipeline.git.branch >> ]
- equal: [ 'chore/fix_react_18_deprecation_warnings', << pipeline.git.branch >> ]
- matches:
pattern: /^release\/\d+\.\d+\.\d+$/
value: << pipeline.git.branch >>
Expand All @@ -83,7 +83,8 @@ windowsWorkflowFilters: &windows-workflow-filters
- equal: [ develop, << pipeline.git.branch >> ]
# use the following branch as well to ensure that v8 snapshot cache updates are fully tested
- equal: [ 'update-v8-snapshot-cache-on-develop', << pipeline.git.branch >> ]
- equal: [ 'renovate/webdriverio-monorepo', << pipeline.git.branch >> ]
- equal: [ 'chore/fix_react_18_deprecation_warnings', << pipeline.git.branch >> ]
- equal: [ 'cacie/fix-du', << pipeline.git.branch >> ]
- matches:
pattern: /^release\/\d+\.\d+\.\d+$/
value: << pipeline.git.branch >>
Expand Down Expand Up @@ -157,7 +158,7 @@ commands:
name: Set environment variable to determine whether or not to persist artifacts
command: |
echo "Setting SHOULD_PERSIST_ARTIFACTS variable"
echo 'if ! [[ "$CIRCLE_BRANCH" != "develop" && "$CIRCLE_BRANCH" != "release/"* && "$CIRCLE_BRANCH" != "bump-win-version-info" ]]; then
echo 'if ! [[ "$CIRCLE_BRANCH" != "develop" && "$CIRCLE_BRANCH" != "release/"* && "$CIRCLE_BRANCH" != "chore/fix_react_18_deprecation_warnings" ]]; then
export SHOULD_PERSIST_ARTIFACTS=true
fi' >> "$BASH_ENV"
# You must run `setup_should_persist_artifacts` command and be using bash before running this command
Expand Down Expand Up @@ -497,9 +498,9 @@ commands:
default: cy-doc
steps:
- run: pwd
- run:
name: print global yarn cache path
command: echo $(yarn global bin)
##- run:
## name: print global yarn cache path and size
## command: du -sh $(yarn global bin)
- run:
name: print yarn version
command: yarn versions
Expand Down Expand Up @@ -776,6 +777,7 @@ commands:
- windows-install-chrome:
browser: <<parameters.browser>>
- run:
name: Run <<parameters.package>> UI tests
command: |
echo Current working directory is $PWD
echo Total containers $CIRCLE_NODE_TOTAL
Expand Down
5 changes: 1 addition & 4 deletions .yarnclean
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,4 @@ wercker.yml
.flowconfig
.documentup.json
.yarn-metadata.json
.travis.yml

# misc
*.md
.travis.yml
6 changes: 5 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ We try to tag all issues with a `pkg/` or `npm/` tag describing the appropriate
You must have the following installed on your system to contribute locally:

- [`Node.js`](https://nodejs.org/en/) (See the root [.node-version](.node-version) file for the required version. You can find a list of tools on [node-version-usage](https://github.com/shadowspawn/node-version-usage) to switch the version of [`Node.js`](https://nodejs.org/en/) based on [.node-version](.node-version).)
- [`Yarn v1 Classic`](https://yarnpkg.com/en/docs/install). If you have [`Node.js`](https://nodejs.org/en/) experimental [corepack](https://nodejs.org/docs/latest/api/corepack.html) enabled, installation of the Yarn package manager will be handled automatically. Attempting to install Yarn globally with npm will fail if [corepack](https://nodejs.org/docs/latest/api/corepack.html) is enabled.
- [`Yarn v1 Classic`](https://yarnpkg.com/en/docs/install) (See also [Corepack](#corepack) below.)
- [`python`](https://www.python.org/downloads/) (since we use `node-gyp`. See their [repo](https://github.com/nodejs/node-gyp) for Python version requirements.)

#### Debian/Ubuntu
Expand All @@ -216,6 +216,10 @@ For Ubuntu `24.04` and above, refer also to the [Ubuntu 24.04 Release notes](htt

Currently no additional instructions for installation requirements.

#### Corepack

The Cypress repo is compatible with Corepack and contains a `packageManager` field in the root [package.json](./package.json) file to automatically install Yarn. Cypress does not however require you to enable Corepack. It is classed as experimental and not suitable for production by the Node.js organization. Refer to the repo [corepack](https://github.com/nodejs/corepack#readme) for instructions, known issues and workarounds.

### Getting Started

The project utilizes [yarn workspaces](https://yarnpkg.com/lang/en/docs/workspaces/) and leverages [lerna](https://lerna.js.org/) to orchestrate running within the context of one or more packages. While it is not as important to understand lerna or yarn workspaces, it **is important** to note that running scripts or installing new dependencies should always happen from the repo's root directory.
Expand Down
10 changes: 7 additions & 3 deletions cli/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,13 @@ _Released 07/01/2025 (PENDING)_
- Removed support for Node.js 18 and Node.js 23. Addresses [#31302](https://github.com/cypress-io/cypress/issues/31302).
- Removed support for [Chrome DevTools Protocol](https://chromedevtools.github.io/devtools-protocol) with the [firefox](https://www.mozilla.org/) browser. Addresses [#31189](https://github.com/cypress-io/cypress/issues/31189).

## 14.2.2
## 14.3.0

_Released 4/8/2025 (PENDING)_
_Released 4/8/2025_

**Features:**

- The [`cy.press()`](https://on.cypress.io/api/press) command is now available. It supports dispatching native Tab keyboard events to the browser. Addresses [#31050](https://github.com/cypress-io/cypress/issues/31050). Addresses [#299](https://github.com/cypress-io/cypress/issues/299). Addressed in [#31398](https://github.com/cypress-io/cypress/pull/31398).

**Bugfixes:**

Expand All @@ -25,7 +29,7 @@ _Released 4/8/2025 (PENDING)_

**Dependency Updates:**

- Upgraded `mocha` from `7.0.1` to `7.1.2`. Addressed in [#31416](https://github.com/cypress-io/cypress/pull/31416).
- Upgraded `mocha` from `7.0.1` to `7.2.0`. Addressed in [#31423](https://github.com/cypress-io/cypress/pull/31423) and [#31432](https://github.com/cypress-io/cypress/pull/31432).
- Upgraded `webdriver` from `9.7.3` to `9.11.0`. Addressed in [#31315](https://github.com/cypress-io/cypress/pull/31315).
- Upgraded `win-version-info` from `5.0.1` to `6.0.1`. Addressed in [#31358](https://github.com/cypress-io/cypress/pull/31358).

Expand Down
201 changes: 108 additions & 93 deletions cli/types/cypress.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -578,99 +578,7 @@ declare namespace Cypress {
*/
stop(): void

Commands: {
/**
* Add a custom command
* @see https://on.cypress.io/api/commands
*/
add<T extends keyof Chainable>(name: T, fn: CommandFn<T>): void

/**
* Add a custom parent command
* @see https://on.cypress.io/api/commands#Parent-Commands
*/
add<T extends keyof Chainable>(name: T, options: CommandOptions & { prevSubject: false }, fn: CommandFn<T>): void

/**
* Add a custom child command
* @see https://on.cypress.io/api/commands#Child-Commands
*/
add<T extends keyof Chainable, S = any>(name: T, options: CommandOptions & { prevSubject: true }, fn: CommandFnWithSubject<T, S>): void

/**
* Add a custom child or dual command
* @see https://on.cypress.io/api/commands#Validations
*/
add<T extends keyof Chainable, S extends PrevSubject>(
name: T, options: CommandOptions & { prevSubject: S | ['optional'] }, fn: CommandFnWithSubject<T, PrevSubjectMap[S]>,
): void

/**
* Add a custom command that allows multiple types as the prevSubject
* @see https://on.cypress.io/api/commands#Validations#Allow-Multiple-Types
*/
add<T extends keyof Chainable, S extends PrevSubject>(
name: T, options: CommandOptions & { prevSubject: S[] }, fn: CommandFnWithSubject<T, PrevSubjectMap<void>[S]>,
): void

/**
* Add one or more custom commands
* @see https://on.cypress.io/api/commands
*/
addAll<T extends keyof Chainable>(fns: CommandFns): void

/**
* Add one or more custom parent commands
* @see https://on.cypress.io/api/commands#Parent-Commands
*/
addAll<T extends keyof Chainable>(options: CommandOptions & { prevSubject: false }, fns: CommandFns): void

/**
* Add one or more custom child commands
* @see https://on.cypress.io/api/commands#Child-Commands
*/
addAll<T extends keyof Chainable, S = any>(options: CommandOptions & { prevSubject: true }, fns: CommandFnsWithSubject<S>): void

/**
* Add one or more custom commands that validate their prevSubject
* @see https://on.cypress.io/api/commands#Validations
*/
addAll<T extends keyof Chainable, S extends PrevSubject>(
options: CommandOptions & { prevSubject: S | ['optional'] }, fns: CommandFnsWithSubject<PrevSubjectMap[S]>,
): void

/**
* Add one or more custom commands that allow multiple types as their prevSubject
* @see https://on.cypress.io/api/commands#Allow-Multiple-Types
*/
addAll<T extends keyof Chainable, S extends PrevSubject>(
options: CommandOptions & { prevSubject: S[] }, fns: CommandFnsWithSubject<PrevSubjectMap<void>[S]>,
): void

/**
* Overwrite an existing Cypress command with a new implementation
* @see https://on.cypress.io/api/commands#Overwrite-Existing-Commands
*/
overwrite<T extends keyof Chainable>(name: T, fn: CommandFnWithOriginalFn<T>): void

/**
* Overwrite an existing Cypress command with a new implementation
* @see https://on.cypress.io/api/commands#Overwrite-Existing-Commands
*/
overwrite<T extends keyof Chainable, S extends PrevSubject>(name: T, fn: CommandFnWithOriginalFnAndSubject<T, PrevSubjectMap[S]>): void

/**
* Add a custom query
* @see https://on.cypress.io/api/custom-queries
*/
addQuery<T extends keyof Chainable>(name: T, fn: QueryFn<T>): void

/**
* Overwrite an existing Cypress query with a new implementation
* @see https://on.cypress.io/api/custom-queries
*/
overwriteQuery<T extends keyof Chainable>(name: T, fn: QueryFnWithOriginalFn<T>): void
}
Commands: Commands

/**
* @see https://on.cypress.io/cookies
Expand Down Expand Up @@ -775,6 +683,9 @@ declare namespace Cypress {
*/
Keyboard: {
defaults(options: Partial<KeyboardDefaultsOptions>): void
Keys: {
TAB: 'Tab',
},
}

/**
Expand Down Expand Up @@ -829,6 +740,100 @@ declare namespace Cypress {
onSpecWindow: (window: Window, specList: string[] | Array<() => Promise<void>>) => void
}

interface Commands {
/**
* Add a custom command
* @see https://on.cypress.io/api/commands
*/
add<T extends keyof Chainable>(name: T, fn: CommandFn<T>): void

/**
* Add a custom parent command
* @see https://on.cypress.io/api/commands#Parent-Commands
*/
add<T extends keyof Chainable>(name: T, options: CommandOptions & { prevSubject: false }, fn: CommandFn<T>): void

/**
* Add a custom child command
* @see https://on.cypress.io/api/commands#Child-Commands
*/
add<T extends keyof Chainable, S = any>(name: T, options: CommandOptions & { prevSubject: true }, fn: CommandFnWithSubject<T, S>): void

/**
* Add a custom child or dual command
* @see https://on.cypress.io/api/commands#Validations
*/
add<T extends keyof Chainable, S extends PrevSubject>(
name: T, options: CommandOptions & { prevSubject: S | ['optional'] }, fn: CommandFnWithSubject<T, PrevSubjectMap[S]>,
): void

/**
* Add a custom command that allows multiple types as the prevSubject
* @see https://on.cypress.io/api/commands#Validations#Allow-Multiple-Types
*/
add<T extends keyof Chainable, S extends PrevSubject>(
name: T, options: CommandOptions & { prevSubject: S[] }, fn: CommandFnWithSubject<T, PrevSubjectMap<void>[S]>,
): void

/**
* Add one or more custom commands
* @see https://on.cypress.io/api/commands
*/
addAll<T extends keyof Chainable>(fns: CommandFns): void

/**
* Add one or more custom parent commands
* @see https://on.cypress.io/api/commands#Parent-Commands
*/
addAll<T extends keyof Chainable>(options: CommandOptions & { prevSubject: false }, fns: CommandFns): void

/**
* Add one or more custom child commands
* @see https://on.cypress.io/api/commands#Child-Commands
*/
addAll<T extends keyof Chainable, S = any>(options: CommandOptions & { prevSubject: true }, fns: CommandFnsWithSubject<S>): void

/**
* Add one or more custom commands that validate their prevSubject
* @see https://on.cypress.io/api/commands#Validations
*/
addAll<T extends keyof Chainable, S extends PrevSubject>(
options: CommandOptions & { prevSubject: S | ['optional'] }, fns: CommandFnsWithSubject<PrevSubjectMap[S]>,
): void

/**
* Add one or more custom commands that allow multiple types as their prevSubject
* @see https://on.cypress.io/api/commands#Allow-Multiple-Types
*/
addAll<T extends keyof Chainable, S extends PrevSubject>(
options: CommandOptions & { prevSubject: S[] }, fns: CommandFnsWithSubject<PrevSubjectMap<void>[S]>,
): void

/**
* Overwrite an existing Cypress command with a new implementation
* @see https://on.cypress.io/api/commands#Overwrite-Existing-Commands
*/
overwrite<T extends keyof Chainable>(name: T, fn: CommandFnWithOriginalFn<T>): void

/**
* Overwrite an existing Cypress command with a new implementation
* @see https://on.cypress.io/api/commands#Overwrite-Existing-Commands
*/
overwrite<T extends keyof Chainable, S extends PrevSubject>(name: T, fn: CommandFnWithOriginalFnAndSubject<T, PrevSubjectMap[S]>): void

/**
* Add a custom query
* @see https://on.cypress.io/api/custom-queries
*/
addQuery<T extends keyof Chainable>(name: T, fn: QueryFn<T>): void

/**
* Overwrite an existing Cypress query with a new implementation
* @see https://on.cypress.io/api/custom-queries
*/
overwriteQuery<T extends keyof Chainable>(name: T, fn: QueryFnWithOriginalFn<T>): void
}

type CanReturnChainable = void | Chainable | Promise<unknown>
type ThenReturn<S, R> =
R extends void ? Chainable<S> :
Expand Down Expand Up @@ -1742,6 +1747,16 @@ declare namespace Cypress {
*/
pause(options?: Partial<Loggable>): Chainable<Subject>

/**
* Send a native sequence of keyboard events: keydown & press, followed by keyup, for the provided key.
* Supported keys index the Cypress.Keyboard.Keys record.
*
* @example
* cy.press(Cypress.Keyboard.Keys.TAB) // dispatches a keydown and press event to the browser, followed by a keyup event.
* @see https://on.cypress.io/press
*/
press(key: typeof Cypress.Keyboard.Keys[keyof typeof Cypress.Keyboard.Keys], options?: Partial<Loggable & Timeoutable>): void

/**
* Get the immediately preceding sibling of each element in a set of the elements.
*
Expand Down
4 changes: 3 additions & 1 deletion cli/types/tslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@
"jsdoc-format": false,
// for now keep the Cypress NPM module API
// in its own file for simplicity
"no-single-declare-module": false
"no-single-declare-module": false,
// This is detecting necessary qualifiers as unnecessary
"no-unnecessary-qualifier": false
},
"linterOptions": {
"exclude": [
Expand Down
Loading