This repository contains a simple example of using Selenium WebDriver to automate interactions with a web application. The code is organized into several classes, each representing a different page or step in a fictional e-commerce checkout process.
LoginPage: Handles interactions with the login page, providing methods to enter credentials and log in. InventoryPage: Represents the inventory page, offering methods for interacting with various elements on the page, such as adding items to the cart or navigating to different sections. CartPage: Represents the shopping cart page, providing methods to remove items from the cart and proceed to checkout.
CheckoutStepOnePage: Represents the first step of the checkout process, allowing users to enter their information.
CheckoutStepTwoPage: Represents the second step of the checkout process, providing a method to complete the checkout. Prerequisites
Java Development Kit (JDK)
Selenium 4
latest version of TestNG as of 21 December 2023
Copy git clone https://github.com/VincentVusi/SauceDemoWebsiteTesting.git
Navigate to the project directory:
Copy cd SauceDemoWebsiteTesting
Run the main class or individual test classes to execute the Selenium WebDriver automation.
Feel free to use, modify, and extend this example for your own Selenium WebDriver projects. Each class has methods for specific interactions with web elements, making it easy to integrate into your testing framework.
![Screenshot 2023-12-21 120433](https://private-user-images.githubusercontent.com/153896296/292168583-75d920f2-ed1e-4f73-94d4-aa2feec83478.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjU3NzE3NTgsIm5iZiI6MTcyNTc3MTQ1OCwicGF0aCI6Ii8xNTM4OTYyOTYvMjkyMTY4NTgzLTc1ZDkyMGYyLWVkMWUtNGY3My05NGQ0LWFhMmZlZWM4MzQ3OC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwOTA4JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDkwOFQwNDU3MzhaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1hZThjOGM0MWM1ZmNjMzkzN2FhNmM1ZGNlN2UxZmJiYTQ1ZWUxZGQ4NThjZjIwMjkyOWMzZTViZWJkODM3MTdiJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.peclCF7nTYyEuGoiHFITffc1BcHKk5nxI4rdFha8lqY)
This project is licensed under the MIT License.