• Skip to main content
  • Skip to primary sidebar
  • Skip to footer
  • Home
  • Programming Languages
    • Java Tutorials
    • Python Tutorials
    • JavaScript Tutorials
  • Automation Tools and Different Tools
    • Web Automation
      • Selenium with Java
        • Selenium Basic
        • Selenium Advance
        • Selenium Realtime
        • Framework
        • Selenium Interview
        • Selenium Videos
        • Selenium with Docker
      • Selenium with Python
      • WebdriverIO
        • Selenium Webdriver C# Tutorial
      • Cypress
      • Playwright
    • TestNG
    • Cucumber
    • Mobile Automation
      • Appium
    • API Testing
      • Postman
      • Rest Assured
      • SOAPUI
    • testRigor
    • Katalon
    • TestProject
    • Serenity BDD
    • Gradle- Build Tool
    • RPA-UiPath
    • Protractor
    • Windows Automation
  • Automation For Manual Testers
  • Services
  • Online Training
  • Contact us
  • About me
  • Follow us
    • Linkedin
    • Facebook Group
    • Facebook Page
    • Instagram

Automation

Selenium WebDriver tutorial Step by Step

You are here: Home / Cypress / Cypress CLI Commands

Cypress CLI Commands

February 21, 2022 by Mukesh Otwani 2 Comments

Cypress CLI Commands

In this post, I will show you how to use Cypress CLI commands in different way.  In order to run test on CI servers like Jenkins, Teamcity, Bamboo etc. you need to learn and understand Cypress CLI commands.

You can also use them when you run your cypress test from Github actions, Github, Azure DevOps etc.

I have a dedicated video on this on my Youtube Channel so please refer below video for the same.

Cypress CLI Commands

 

 

 

Make sure you have cypress installed correctly in your system before running CLI commands.

Get Cypress Info
npx cypress info

Verify Cypress
npx cypress verify

Cypress Version
npx cypress version

 

Run all spec files
npx cypress run

Run specific test from cmd
npx cypress run –spec “cypress\integration\testscripts\Login.spec.js”

Run multiple spec file from cmd
npx cypress run –spec “cypress\integration\testscripts\Login.spec.js,cypress\integration\testscripts\FirstCypress.spec.js”

Run using wildcard *
npx cypress run –spec “cypress\integration\**\regression*”

Run with headed mode and noexit flag
npx cypress run –headed –no-exit –spec “cypress\integration\testscripts\Login.spec.js”

Run on chrome browser
npx cypress run –browser chrome –spec “cypress\integration\testscripts\Login.spec.js”

Run on edge with headed mode on
npx cypress run –browser edge –headed –spec “cypress\integration\testscripts\Login.spec.js”

Run on firefox with headed mode on
npx cypress run –browser firefox –headed –spec “cypress\integration\testscripts\Login.spec.js”

To update browser list
npx browserslist@latest –update-db

If you face any issue while executing above commands then feel free to comment below.

 

Filed Under: Cypress Tagged With: Cypress CLI Commands

Reader Interactions

Comments

  1. Yashprabha says

    March 29, 2023 at 1:45 PM

    Do you run any cypress course please?

    Reply
    • Mukesh Otwani says

      July 24, 2023 at 1:05 AM

      I had one course last year in June but after that no new batches after that.

      Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Free Selenium Videos

https://www.youtube.com/watch?v=w_iPCT1ETO4

Search topic

Top Posts & Pages

  • Selenium Webdriver tutorial for beginners
  • How To Fix Eclipse Autocomplete Or Code Suggestion In Eclipse
  • Selenium Webdriver C# Tutorial
  • WHAT ARE YOUR EXPECTATIONS FROM US?

Stay connected via Facebook

Stay connected via Facebook

Archives

Footer

Categories

Recent Post

  • API Testing Using Postman And RestAssured
  • Disable Personalise Your Web Experience Microsoft Edge Prompt In Selenium
  • How To Fix Error: No tests found In Playwright
  • How To Fix Eclipse Autocomplete Or Code Suggestion In Eclipse
  • Best and easy way to Group test cases in selenium

Top Posts & Pages

  • Selenium Webdriver tutorial for beginners
  • How To Fix Eclipse Autocomplete Or Code Suggestion In Eclipse
  • Selenium Webdriver C# Tutorial
  • WHAT ARE YOUR EXPECTATIONS FROM US?