This project is an Enterprise Selenium Cucumber Hybrid Automation Framework developed using Java, Selenium WebDriver, Cucumber, JUnit, Maven, and the Page Object Model (POM).
The framework is designed to be scalable, reusable and maintainable, following industry best practices for UI test automation.
The application under test is Automation Exercise.
| Technology | Purpose |
|---|---|
| Java | Programming Language |
| Selenium WebDriver | Web UI Automation |
| Cucumber | Behaviour Driven Development (BDD) |
| JUnit | Test Execution |
| Maven | Build & Dependency Management |
| Log4j2 | Logging |
| Extent Reports | HTML Reporting |
| Git & GitHub | Version Control |
Feature Files
│
▼
Step Definitions
│
▼
Hooks
│
▼
Page Objects
│
▼
WebActions
│
▼
Selenium WebDriver
│
▼
Automation Exercise
src
└── test
├── java
│ ├── base
│ ├── hooks
│ ├── pages
│ ├── reports
│ ├── runner
│ ├── stepdefinitions
│ └── utilities
│
└── resources
├── features
├── config.properties
└── log4j2.xml
The framework follows a layered architecture to promote maintainability and code reuse.
- BaseTest
- BasePage
- HomePage
- LoginPage
- SignupPage
- ProductsPage
- CartPage
- EnvironemntUtils
- WaitUtils
- TestDataReader
- ScreenshotUtils
- LoggerUtils
- ConfigReader
- Extent Reports
- Cucumber Reports
- Page Object Model (POM)
- Base Page Design
- Singleton Pattern (Extent Reports)
- Utility Class Pattern
- ThreadLocal (Extent Report Management)
- User Registration
- User Login
- Logout
- Delete Account
- Search Product
- View Product Details
- Add Product to Cart
- View Cart
- Remove Product
- Verify Empty Cart
- Behaviour Driven Development (BDD)
- Page Object Model (POM)
- Reusable WebActions Utility
- Centralized Configuration Management
- Explicit Wait Utilities
- Log4j2 Logging
- Extent Reports
- Cucumber HTML Reports
- JSON Reports
- XML Reports
- Automatic Screenshot Capture on Failure
- Reusable Hooks for Test Setup & Cleanup
- Maven Build Support
- Modular Framework Design
The framework generates the following reports:
- Extent HTML Report
- Cucumber HTML Report
- Cucumber JSON Report
- Cucumber XML Report
Screenshots are automatically captured and attached whenever a scenario fails.
Log4j2 is integrated throughout the framework.
Logs are generated for:
- Framework Initialization
- Browser Launch
- Application Navigation
- Page Actions
- Test Data Reading
- Assertions
- Screenshot Capture
- Test Completion
git clone https://github.com/Dishi-Gogia/cucumber-java-hybrid-framework.gitcd cucumber-java-hybrid-frameworkmvn clean installmvn clean testor execute:
src/test/java/runner/TestRunner.java
directly from your IDE.
target
│
├── cucumber-reports
│ ├── CucumberReport.html
│ ├── CucumberReport.json
│ └── CucumberReport.xml
│
├── extent-reports
│ └── ExtentReport.html
│
└── screenshots
- Parallel Execution
- Cross Browser Execution
- Selenium Grid Integration
- Docker Integration
- GitHub Actions CI/CD
- Jenkins Pipeline
- BrowserStack Integration
- Allure Reports
- REST Assured API Framework Integration
Dishi Gogia
Senior QA Automation Engineer
GitHub
https://github.com/Dishi-Gogia
https://www.linkedin.com/in/dishi-gogia