To check the installed Cypress version, use the command line tool. Here is a step-by-step guide:
-
Open the command line tool:
- On Windows, open Command Prompt or PowerShell.
- On macOS or Linux, open Terminal.
-
Navigate to the project directory:
- Use the
cdcommand to navigate to the directory containing Cypress. For example:bashcd path/to/your/project
- Use the
-
Check the Cypress version:
- Within the project directory, run the following command to check the Cypress version:
bash
npx cypress --version
Alternatively, if Cypress is globally installed, run:
bashcypress --version - Within the project directory, run the following command to check the Cypress version:
This command outputs the Cypress version information, including the major, minor, and patch versions. Additionally, it may display other related version information, such as the Electron version and the bundled Node.js version.
Example: Assuming your project has Cypress installed and you have navigated to the project directory and executed the version check command, the output may appear as:
shellCypress package version: 7.5.0 Cypress binary version: 7.5.0 Electron version: 12.0.0-beta.14 Bundled Node version: 14.16.0
This allows you to identify the specific Cypress version installed in your project.
2024年6月29日 12:07 回复