A Selenium WebDriver automation framework built using Java, Maven, and Cucumber (BDD) to implement automated UI tests for the SauceDemo web application.
This project demonstrates real-world automation framework design, BDD implementation, and CI/CD integration using GitHub Actions, along with live HTML test reporting via GitHub Pages.
SauceDemo
👉 https://www.saucedemo.com
- Behaviour Driven Development (BDD) using Cucumber & Gherkin
- Page Object Model (POM) for maintainable and scalable automation
- Thread-safe WebDriver management using 'ThreadLocal'
- Centralised configuration using 'config.properties'
- Automated execution via GitHub Actions (CI)
- Live Cucumber HTML test reports published using GitHub Pages
- Java 17
- Selenium WebDriver
- Cucumber (BDD)
- JUnit
- Maven
- WebDriverManager
- Git & GitHub
- GitHub Actions (CI/CD)
Test configuration is managed via:
src/test/resources/config/config.properties
Example: 'properties'
browser=chrome
url=https://www.saucedemo.com/
username=standard_user
password=secret_sauce
-
Clone the repository
git clone https://github.com/renishpadariya/selenium-cucumber-java-framework.git
cd selenium-cucumber-java-framework
-
Import the project into Eclipse
- Go to File → Import → Maven → Existing Maven Project
- Select the project root folder
-
Install dependencies
- Maven will automatically download required dependencies from pom.xml
-
Run tests
From Eclipse:
Right-click on your test runner classes → Run As → JUnit Test
After local execution: target/index.html
Cucumber HTML reports are automatically published via GitHub Pages on every successful CI run:
https://renishpadariya.github.io/selenium-cucumber-java-framework/
CI pipeline triggers on push and pull requests to master
Executes Selenium tests in headless Chrome on Ubuntu runners
Uploads test results as build artifacts
Publishes live HTML reports to GitHub Pages
