An open API service indexing awesome lists of open source software.

https://github.com/prasad8400/e2e-testframework-swaglabs-bdd

End-to-end test automation framework for Swag Labs using Java, Selenium, Cucumber (BDD), and TestNG. Designed for maintainability and CI/CD readiness, featuring parallel execution, custom reports, and external config support.
https://github.com/prasad8400/e2e-testframework-swaglabs-bdd

bdd-framework cucumber java maven selenium-java selenium-webdriver testng

Last synced: about 1 month ago
JSON representation

End-to-end test automation framework for Swag Labs using Java, Selenium, Cucumber (BDD), and TestNG. Designed for maintainability and CI/CD readiness, featuring parallel execution, custom reports, and external config support.

Awesome Lists containing this project

README

          

# E2E-TestFramework-SwagLabs-BDD
End-to-end test automation framework for Swag Labs using Java, Selenium, Cucumber (BDD), and TestNG. Designed for maintainability and CI/CD readiness, featuring parallel execution, custom reports, and external config support.
# SwagLabs_Ecom_Automation (BDD Framework)

![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)

[![Certifications & Awards](https://img.shields.io/badge/Certifications%20%26%20Awards-10-blue)](https://github.com/Prasad8400/My_AwardsAndCertifications/blob/main/My_AwardsAndCertifications.md)

[![Java](https://img.shields.io/badge/Java-ED8B00?style=flat&logo=java&logoColor=white)](https://www.java.com/)
[![Selenium](https://img.shields.io/badge/Selenium-43B02A?style=flat&logo=selenium&logoColor=white)](https://www.selenium.dev/)
[![TestNG](https://img.shields.io/badge/TestNG-FF6C37?style=flat&logo=testng)](https://testng.org/)
[![Maven](https://img.shields.io/badge/Maven-C71A36?style=flat&logo=apachemaven)](https://maven.apache.org/)
[![Cucumber](https://img.shields.io/badge/Cucumber-BDD-green?style=flat&logo=cucumber)](https://cucumber.io/)

This project is a robust, scalable **Selenium WebDriver automation framework** built for testing the [Swag Labs](https://www.saucedemo.com/) e-commerce platform using **Java 17**, **Cucumber (BDD)**, **TestNG**, and **Maven**.

It leverages the **Page Object Model (POM)** design pattern for maintainability and supports cross-browser execution with detailed reporting.

## πŸš€ Features

- βœ… BDD with Cucumber (Gherkin syntax)
- βœ… Page Object Model (POM) design
- βœ… Parallel test execution with TestNG
- βœ… Browser support (Chrome, Firefox)
- βœ… External configuration via `config.properties`
- βœ… Detailed HTML report generation
- βœ… Maven for dependency and build management
- βœ… Java 17 and Eclipse IDE

## πŸ“‚ Project Structure

src
β”œβ”€β”€ main
β”‚ └── resources
β”œβ”€β”€ test
β”‚ β”œβ”€β”€ java
β”‚ β”‚ β”œβ”€β”€ base/ # WebDriver setup and BaseTest
β”‚ β”‚ β”œβ”€β”€ pages/ # Page Object classes
β”‚ β”‚ β”œβ”€β”€ steps/ # Cucumber step definitions
β”‚ β”‚ β”œβ”€β”€ testRunners/ # Cucumber TestNG runner
β”‚ β”‚ └── utils/ # Report & Config utilities
β”‚ └── resources
β”‚ β”œβ”€β”€ features/ # Cucumber feature files
β”‚ └── config.properties # External config

## πŸ›  Tech Stack

| Tool | Description |
|---------------------|----------------------------------------|
| Java 17 | Language |
| Selenium WebDriver | Browser Automation |
| Cucumber | BDD Framework |
| TestNG | Test Execution |
| Maven | Build & Dependency Management |
| Eclipse IDE | Development Environment |

## πŸ“ˆ Reporting

The framework supports rich HTML reporting via external Report Manager (`utils/ReportManager.java`) and is configured for scalable test result output.

## πŸ’Ό Skills Demonstrated

- βœ… Test automation framework design
- βœ… Page Object Model (POM) implementation
- βœ… Behavior-Driven Development with Cucumber
- βœ… CI/CD readiness using Maven
- βœ… Cross-browser automation setup
- βœ… External configuration management
- βœ… TestNG parallel test setup
- βœ… Extensive use of Object-Oriented Programming (OOP) principles:
πŸ”ΉEncapsulation – Data hiding and getter/setter usage in page classes
πŸ”ΉAbstraction – Reusable base classes and utility methods
πŸ”ΉInheritance – Common test setup inherited from base test class
πŸ”ΉPolymorphism – Method overriding (e.g., WebDriver setup across browsers)

## πŸš€ Getting Started

```bash
# Clone the repo
git clone https://github.com/your-username/SwagLabs_Ecom_Automation.git

# Navigate to project directory
cd SwagLabs_Ecom_Automation

# Run tests with Maven
mvn clean test
```

## πŸ”§ Configuration

src/test/resources/config.properties

## πŸ“¬ Contact

- πŸ“§ Email: prasadsutar6544@gmail.com
- πŸ’Ό LinkedIn: [linkedin.com/in/prasadsutar8400](https://www.linkedin.com/in/prasadsutar8400/)