This project contains Selenium WebDriver scripts for automating various web interactions using Google Chrome. It demonstrates browser invocation, navigation commands, form filling, and validation tests on different websites.
Before running the scripts, ensure you have the following installed:
- Java Development Kit (JDK) 8 or later
- Selenium WebDriver
- ChromeDriver (compatible with your Chrome browser version)
- An IDE (Eclipse, IntelliJ IDEA, or VS Code)
WorkingWithChrome.java
: Automates browser interactions such as navigation and validation.Guru99Project.java
: Automates login and customer registration on the Guru99 demo site (https://demo.guru99.com/V4/).newFacebook.java
: Automates Facebook account creation (for demonstration purposes).
-
Download and Install Dependencies:
- Download Selenium WebDriver from SeleniumHQ.
- Download ChromeDriver from ChromeDriver Site and place it in your system PATH.
-
Clone the Repository:
git clone https://github.com/sasmithaK/hands-on-selenium.git cd hands-on-selenium
-
Update ChromeDriver Path:
- Open Java files and replace
path/to/chromedriver.exe
with the actual path wherechromedriver.exe
is located.
- Open Java files and replace
- To execute the automation scripts, run the
main
method in the respective Java files using your preferred IDE or command line.
- Ensure that ChromeDriver and Google Chrome are compatible versions.
- Avoid hardcoding sensitive credentials; use environment variables or secure vaults instead.