Skip to content

chemyl/cypress_typescript

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 

Repository files navigation

Sample project to UI Automation testing with Cypress on Type Script

Getting Started

  • install npm on machine = npm install -g npm
  • create workspace
  • create package.json = npm init -y
  • install cypress = npm install cypress
  • install typescript = npm install -D typescript
  • check package.json with dependencies and dev_dependencies
  • add command to package.json scripts section
    • cypress:open": "cypress open",
    • "cypress:run": "cypress run"
  • add new test file testsuite.cy.ts
  • add file tsconfig.json to the root folder
  • run cypress = npm run cypress:open
  • select spec test-case and launch

Covered topics

  • spec.cy.ts | CSS locators strategy and syntax
  • options.cy.ts | cy.get() with options and alias
  • sync.cy.ts | sync / async mode with TS and Cy commands
  • browser_elements.cy.ts | fetching element properties
  • drop_down_element.cy.ts | dropdown web elements fetching value and text
  • contains_method.cy.ts | contains method for select strategy

For more information visit Cypress page https://docs.cypress.io/guides/overview/why-cypress/

Releases

No releases published

Packages

No packages published