Wednesday, 17 May 2017

Working with different browser drivers.

To work with any browser, we need the executable driver for specific browsers. Here, I will explain about 3 major browsers & their executable driver that we are using in Windows environment.
1
Mozilla Firefox
Geckodriver.exe
System.setProperty(“webdriver.gecko.driver”,”/path/to/geckodriver.exe”)
2
Chrome
Chromedriver.exe
System.setProperty(“webdriver.chrome.driver”,”/path/to/chromedriver.exe”)
3
IE
IEDriverServer.exe
System.setProperty(“webdriver.ie.driver”,”/path/to/ IEDriverServer exe”)

Downloading WebDriver jars & configuring in eclipse.

The latest version of selenium web driver is 3.x. To use Selenium 3.0x the minimum requirement is JAVA8+. If we are using Selenium 3.x then you can use Mozilla latest version. If it’s failing to load Mozilla latest version then use latest – 1 version of Mozilla.
To download web driver jars, open the selenium official site (http://www.seleniumhq.org), go to Download section, Under JAVA click on download link to download the .zip file.
Once you download the .zip file, Extract the .zip file & keep it in your workspace directory. If you open the extracted folder then you can see lib folder where all the dependency jars are present.

Tuesday, 16 May 2017

Introduction to Selenium Web Driver.

Selenium-WebDriver was developed to better support dynamic web pages where elements of a page may change without the page itself being reloaded. WebDriver’s goal is to supply a well-designed object-oriented API that provides improved support for modern advanced web-app testing problems.
Selenium Web Driver was developed in such a way that, it can support Multiple Browsers, the code can be written in Multiple Languages & can be executed in Multiple Platforms.
            Selenium Webdriver Architecture:
            Selenium web driver works on 3 components as mentioned below:
Figure 4: Selenium Webdriver Architecture