Posts

Showing posts from August, 2021

Cypress framework overview

  Fixtures: The fixture folder in cypress is used to store external files which can be used by the test cases like excel, JSON, YAML, CSV, etc. By default, cypress provide us the fixture folder to accumulate all the external files in this folder Integration: The integration folder contains the test specs (test case) files which are our actual test cases. This is also a default folder created when we use cypress first time. We can as many folders or files as we can create to segregate our test cases. Plugins: By default, cypress provide plugins/index.js file to load any external configuration that we need to run our test scripts Plugins enable us to tap into, modify, or extend the internal behavior of Cypress. Plugins are a "seam" for us to write our own custom code that executes during particular stages of the Cypress lifecycle. Support: Cypress provides another folder called support where we can write our customized commands, reusable code, or utilities that can be used whil...

Cypress run command

To run particular test spec file  node_modules/.bin/cypress run -s "cypress/integration/examples/Test1.js" To run all the test present under cypress folder node_modules/.bin/cypress run  To open cypress test runner UI node_modules/.bin/cypress open To execute cypress test in particular browser (by default cypress run in headless mode) node_modules/.bin/cypress run --browser {browserName}