Software Testing Learning Hub

Configure Selenium on your Computer

Lesson 2 - configure selenium

 

It is often challenging to setup the selenium on machine and get it working. if you are beginner then it become more tough. this lessons will guide and provide step by step way to setup the Selenium with Eclipse.

in this lesson we will configure

  • Setup Selenium IDE:
  • Setup Selenium Webdriver with eclipse 

Setup Selenium IDE:

Selenium IDE is Firefox plugin, so you will required Firefox on your computer.  if you don’t have Firefox installed, you can download it from following link:

Firefox installation link

once firefox installed, follow the following steps to install Selenium plugin.

  1. Launch Firefox
  2. Open Selenium IDE download page http://docs.seleniumhq.org/download/
  3. In Selenium IDE section, Click on latest IDE version link. download the file

Lesson 2 - Selenium IDE

4. Click on “Allow” button, it will download the selenium IDE xpi file and install dialog will pop up.

Lesson 2 - Selenium IDE install

5. Click on “Install” button. plugin will get installed, restart popup will appear

Lesson 2 - Selenium IDE restart

6.  Click on “Restart” button , firefox will get restarted.

7.  Go to “Tools” Menu, you will see the selenium IDE option

Lesson 2 - Selenium IDE installed

      8.  you are done!!!!

Setup Selenium Webdriver with Java:

To setup selenium webdriver, you should have following…

  1. Selenium webdriver Bindings ( in our case we will required Java bindings)
  2. JRE/JDK – java Runtime/Development environment,
  3. IDE – we will use Eclipse

Following steps will guide you setup selenium webdriver.

1. download all required software and bindings

 Selenium Webdriver bindings : Link : http://docs.seleniumhq.org/download/  : select the latest binding for java in “Selenium Client & WebDriver Language Bindings” section. and extract the zip file

Lesson 2 - selenium webdriver install

 

Download  and install JDK from http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

Download the Eclipse from https://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/indigosr2

you don’t need to install Eclipse as it is dump, you just need to run the executable.

2. Setup the Java in Environmental variable :  follow the steps mentioned below to setup the JRE in environmental variable ( for Win 7).

  1. Click on Start button
  2. Right click on My Computer > select properties
  3. Select Advance System Properties, it will popup ” System properties”
  4. Click on “Environmental Variables…” button. it will pop up, dialog
  5. in “System variables” section, select “path” and click on “Edit” button. if Path variable is not defined then create new variable.
  6. Now in path, you have enter the JRE path. typically the path is “C:\Program Files (x86)\Java\jre7\bin”
  7. Save and Exit.

3. Configuring the Selenium Webdriver: now you have setup the JRE, next step to configure the Selenium Webdriver.

follow the steps:

  1. Run Eclipse
  2. select or put the workspace path ( it is the path where you want to create projects)
  3. Create JAVA project in Eclipse
  4. Go to File menu > Properties, it will launch properties dialog.
  5. Select the “Libraries” tab
  6. Click on “Add external Jar” button
  7. Now select the Selenium webdriver Jar files which you have extracted.
  8. Click on “OK” button
  9. you are done!!!

now you have configured the Selenium webdriver !

If you have any queries please reply to this post and get the answers. Happy Learning!