How To Setup : Selenium Web Driver - tooltwist/documentation GitHub Wiki
Steps on how to setup the Selenium Web Driver:
- Download Eclipse (Note: Ideal is the latest Eclipse version)
- Download Selenium Web Driver package (https://code.google.com/p/selenium/downloads/detail?name=selenium-java-2.33.0.zip&can=2&q=selenium+webdriver)
- Create a new folder and rename it (e.g. Selenium Test Toolkit)
- Copy the downloaded file (Eclipse) into the new folder created (e.g. Selenium Test Toolkit)
- Unzip the Eclipse and Selenium Web Driver files under the same folder
- Open the Eclipse folder from the unzipped file. Click on the Eclipse Application
- Select/Create a workspace (e.g. /Users/Admin/Documents/workspace)
- Once the Eclipse Application is opened, create a Java Project
- Right click on the Package Explorer section. Select _New >> Java Project _
- The New Java Project screen will open. Type in the required Project Name on the "Project name" field. e.g. ("HubWebDriver")
- Click on the Finish button
-
"HubWebDriver" Project is now created.
- Right click on the "HubWebDriver" project. Select New >> Folder
- New Folder screen will open. Type in "lib" on the folder name field. Click Finish.
- Go to the "Selenium Test Toolkit" folder >> selenium-x.xx.xx folder >> selenium-x.xx.x folder >> selenium-xx.xx.x folder.
- Copy selenium-java-x.xx.x-srcs.jar and selenium-java-x.xx.x.jar and paste it on the "HubWebDriver" Project >> lib folder on the Eclipse application.
- Go back again to "Selenium Test Toolkit" >> selenium-x.xx.xx folder >> selenium-x.xx.x folder > selenium-xx.xx.x folder >> libs folder.
- Copy all the existing libraries from the libs folder to "HubWebDriver" Project >> lib folder on the Eclipse application.
- Right click on the "HubWebDriver" Project. Select Build Path >> Configure Build Path
- Properties for "HubWebDriver" screen will open. Click on the "Add JARs…" button located on the right side of the screen.
- On the JAR Selection screen, select HubWebDriver Project >> lib folder. Select all the existing jar files under the lib folder. Once they are all selected, click on the OK button.
- On the Properties for "HubWebDriver" screen, click on the "Add Library…" button located on the right of the screen.
- Select on the JUnit. Click on the Next button. Select JUnit 4 as the JUnit library version. Click on the Finish button.
- Once the JUnit library is added, click OK button on the Properties for HubWebDriver screen.
- Right click on the "src" folder under the "HubWebDriver" Project. Select New >> Package
- On the New Java Package screen, type the desired Package "Name" on the Name field. e.g. "com.hub.test.smoke". Click on the Finish button.
- Install Selenium IDE in Firefox. (e.g. Go to http://docs.seleniumhq.org/download/. Click on the latest release version link (2.x.x) )
- Using Selenium IDE, you can now create the Java Web Driver test cases.