Skip to content

rizbiislam/saucedemo-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🎉 Welcome to the SuccessDemo Test Framework! 🎉

Created an end-to-end test automation framework for the SauceDemo eCommerce website using Selenium WebDriver and TestNG. The framework follows the Page Object Model (POM) for clean, maintainable code and automates key scenarios such as login, select random products, check products total price, cart management, and checkout.

This framework is designed for robust automation testing using Java. It includes:

  • Selenium for browser automation
  • JUnit and TestNG for structured test management
  • Allure Reporting for insightful test reports
  • Error Screenshots and more to streamline testing!

🚀 Getting Started

1. Set Up a Maven Project

  • Create a Maven project as usual or set it up from scratch.

2. Configure pom.xml

  • Add the provided dependencies and plugins in your pom.xml file.

3. Create Folder Structure

  • Go to src/test/java and create these folders:
    • pages
    • utilities
    • tests

4. Import Files

  • Option 1: Import each file manually into the corresponding folders.
  • Option 2: Download the complete src/test/java folder and replace it in your project.

5. Configure the Driver Path

  • A drivers folder is included with Chrome, Edge, and Firefox drivers.
  • Set the driver path in BaseTest.java as shown below:
    System.setProperty("webdriver.chrome.driver", "drivers/chromedriver.exe");
  • Or, if using Selenium 4+, use:
    WebDriverManager.chromedriver().setup();

6. Add testing.xml

  • Download testing.xml and place it in your project directory to manage test execution.

7. Run Your Tests 🚦

  • Save your project and run it. The allure-report and screenshot folders will be generated automatically during test execution.

8. Generate Allure HTML Report

  • Run the following command to serve the Allure report:
    allure serve <path_to_allure_results>
  • Alternatively, navigate to the allure-report folder in your file explorer, open a command prompt from that location, and then use:
    allure serve

Enjoy using the SuccessDemo Test Framework!

📊 View My Allure HTML Report

Once your tests have run, view the Allure report in your browser:

  1. Automatic Link
    Open this link directly: Allure Report

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages