https://github.com/rajatt95/tutorial_yt_rajat_designpattern_pom_cypress_js
This repository contains a Tutorial for Page Object Model (POM) design pattern implementation using Cypress and Javascript for automated testing of applications.
https://github.com/rajatt95/tutorial_yt_rajat_designpattern_pom_cypress_js
chrome cypress edge electron firefox javascript nodejs page-object-model vscode
Last synced: 3 months ago
JSON representation
This repository contains a Tutorial for Page Object Model (POM) design pattern implementation using Cypress and Javascript for automated testing of applications.
- Host: GitHub
- URL: https://github.com/rajatt95/tutorial_yt_rajat_designpattern_pom_cypress_js
- Owner: rajatt95
- Created: 2023-11-15T17:27:52.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-11-18T04:07:34.000Z (over 1 year ago)
- Last Synced: 2025-02-02T18:33:18.597Z (4 months ago)
- Topics: chrome, cypress, edge, electron, firefox, javascript, nodejs, page-object-model, vscode
- Language: JavaScript
- Homepage: https://www.youtube.com/@rajatt95
- Size: 43 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
---
# 💻 Tutorial | Page Object Model (POM)[](https://www.cypress.io/) [](https://js.org/index.html)
[](https://code.visualstudio.com/)
[](https://en.wikipedia.org/wiki/Page_Object_Model)## 📑 Table of Contents
- [Introduction](#introduction)
- [Video Tutorial](#video-tutorial)
- [Prerequisites](#prerequisites)
- [Getting Started](#getting-started)
- [Running Tests](#running-tests)
- [Project Structure](#project-structure)
- [Configuration](#configuration)
- [Other Projects](#other-projects)
- [Technical Documents](#technical-documents)
- [Contacts](#contacts)## 📖 Introduction
This repository contains a Tutorial for Page Object Model (POM) design pattern implementation using Cypress and Javascript for automated testing of applications.## 🎥 Video Tutorial
Click on the image above to watch the tutorial.
## 🛠️ Prerequisites
- [](https://nodejs.org/) (v18.16.1 or higher recommended)
- [](https://www.npmjs.com/) (v9.5.1 or higher recommended)## ▶️ Getting Started
1. Clone the repository:
```bash
git clone https://github.com/rajatt95/Tutorial_YT_Rajat_DesignPattern_POM_Cypress_JS.git
```2. Navigate to the project directory:
```bash
cd Tutorial_YT_Rajat_DesignPattern_POM_Cypress_JS
```3. Install dependencies:
```bash
npm install
```## 🚀 Running Tests
- Open Cypress Test Runner:
```bash
npm run cy:open
```
- Run tests in different browsers:- [](https://www.google.com/chrome/)
[](https://www.mozilla.org/firefox/)
[](https://www.microsoft.com/edge/)
[](https://www.electronjs.org/)
```bash
npm run cy:tests:CHROME
```
```bash
npm run cy:tests:FIREFOX
```
```bash
npm run cy:tests:EDGE
```
```bash
npm run cy:tests:ELECTRON
```- Run tests in different modes (Headless):
```bash
npm run cy:tests:ELECTRON:HEADLESS
```## 📁 Project Structure
The tests follow a modular and maintainable structure:
```
|-- cypress
| |-- e2e
| |-- Sauce_Demo
| |-- Login.cy.js
| |-- support
| |-- pages
| |-- components
| |-- Header.js
| |-- Footer.js
| |-- BasePage.js
| |-- LoginPage.js
| |-- ProductsPage.js
| |-- commands.js
| |-- e2e.js
|-- .gitignore
|-- cypress.config.js
|-- package.json
```
- `cypress/e2e`: Contains the actual test files. You can organize your tests into subdirectories as needed.
- `cypress/support`: Contains custom commands and global configuration.
- `cypress/support/pages`: Contains the Page Object Model (POM) classes representing web pages and their elements.
- `cypress/plugins`: Contains plugins used by Cypress.## ⚙️ Configuration
- Modify `cypress.config.json` for Cypress configuration settings.
- Customize `commands.js` and other files in `cypress/support` for reusable commands.## 🔭 Other Projects
- [](https://github.com/stars/rajatt95/lists/programming-language-java) -
[](https://github.com/stars/rajatt95/lists/selenium-automation-frameworks)
[](https://github.com/stars/rajatt95/lists/appium-automation-frameworks)
[](https://github.com/stars/rajatt95/lists/restassured-automation-framework)- [](https://github.com/stars/rajatt95/lists/programming-language-javascript) -
[](https://github.com/stars/rajatt95/lists/cypress-automation-frameworks)
[](https://github.com/stars/rajatt95/lists/playwright-automation-frameworks)- [](https://github.com/stars/rajatt95/lists/programming-language-python) -
[](https://github.com/stars/rajatt95/lists/requests-automation-framework)## 📄 Technical Documents
- [](https://drive.google.com/drive/folders/1tne9pZjgWvfrS0l9tVHs6k1jnQHpTLoA?usp=sharing)
- [](https://github.com/rajatt95/Documents)## 📧 Contacts
- [](mailto:[email protected])
- [](https://github.com/rajatt95)
- [](https://rajatt95.github.io/)
- [](https://www.linkedin.com/in/rajatt95)
- [](https://topmate.io/rajatt95)
- [](https://t.me/rajatt95)
- [](https://www.instagram.com/rajattvermaa95/)
- [](https://www.youtube.com/@rajatt95)
- [](https://chat.whatsapp.com/LP20xMGvxnEL88GoB58bo1)
- [](https://whatsapp.com/channel/0029Va9XXMhJ93waOU5Xer3r)Feel free to reach out if you have any questions, or suggestions, or just want to chat!
Thanks for visiting my GitHub profile! 😊
![]()