install cypress code example
Example 1: install cypress
npm install cypress or npm install cypress --save-dev // Make sure that you have already run npm init
./node_modules/.bin/cypress open //to open cypress window, will take 30 secs
Example 2: open cypress window
./node_modules/.bin/cypress open // just cypress open wont work
Example 3: run cypress
./node_modules/.bin/cypress open
Example 4: install cypress
//Install Cypress
npm install cypress --save-dev or yarn add cypress --dev
//Open Cypress
node_modules/.bin/cypress open
or
add "cypress": "cypress open" in your package.json then npm run cypress
Example 5: cypress run all files in folder
I think you're looking for --spec path/to/folder/*.js
You can run all the tests in a folder, or even in all subfolders of a folder
example: --spec cypresss/integration/subsetA/**/*.js
would run all .js files in all folders under the "subsetA" folder in cypress/integration.