Selenium 2.x / Web Driver             By        Aparna Naik    www.DestinationQA.com                                1     ...
AgendaWhat is WebDriverWebDriver Interface and ImplementationsFirefox DriverInternet Explorer DriverHTML Unit DriverOther ...
Web DriverIs a Self Contained Library• No Proxy Server like RC• Acts just as any normal libraryHas Extensive API• Easy to ...
Web Driver Interface  Selenium JavaDoc  Base class for different browsers  The main interface to use for testing  Represen...
Web Driver WebDriver Interface          Internet   HTMLFirefox                         Opera       Chrome    iPhone    And...
Firefox DriverControls the Firefox browser using aFirefox pluginUses a stripped down profile fromwhat is installed on the ...
Firefox DriverUsage           WebDriver driver = new           FirefoxDriver();OS         Windows           Mac           ...
Firefox Driver    - Runs in a real - Slower than the    browser and       HtmlUnit Driver    supports    JavaScript    - F...
Internet Explorer DriverStructure   This driver is controlled by a .dll and is            thus only available on Windows O...
Internet Explorer Driver                     Comparatively slow   Runs in a real XPath is not natively   browser and      ...
HtmlUnit DriverStructure   The fastest and most lightweight of            Drivers. Based on HtmlUnit.            HtmlUnit ...
HtmlUnit Driver    Fastest                    Emulates other    implementation of          browsers’    WebDriver         ...
Java Script in HtmlUnit HtmlUnit’s Java Script engine (Rhino) is not used by other popular browsers What does this mean?...
Other Drivers    Chrome Driver    Opera Driver    iPhone Driver    Android Driver                                    14   ...
Thank You…Aparna NaikEmail: naik.aparna@destinationqa.comTel: +91 99233 50980                                             ...
Upcoming SlideShare
Loading in …5
×

Selenium drivers

3,413 views

Published on

Published in: Technology
2 Comments
0 Likes
Statistics
Notes
  • Be the first to like this

No Downloads
Views
Total views
3,413
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
0
Comments
2
Likes
0
Embeds 0
No embeds

No notes for slide

Selenium drivers

  1. 1. Selenium 2.x / Web Driver By Aparna Naik www.DestinationQA.com 1 www.destinationqa.com
  2. 2. AgendaWhat is WebDriverWebDriver Interface and ImplementationsFirefox DriverInternet Explorer DriverHTML Unit DriverOther Drivers 2 www.destinationqa.com
  3. 3. Web DriverIs a Self Contained Library• No Proxy Server like RC• Acts just as any normal libraryHas Extensive API• Easy to maintain• Robust scripting support 3 www.destinationqa.com
  4. 4. Web Driver Interface Selenium JavaDoc Base class for different browsers The main interface to use for testing Represents an idealised web browser Methods of WebDriver • Control of the browser itself • Selection of WebElements • Debugging aids 4 www.destinationqa.com
  5. 5. Web Driver WebDriver Interface Internet HTMLFirefox Opera Chrome iPhone Android Explorer Unitdriver Driver Driver Driver Driver Driver driver 5 www.destinationqa.com
  6. 6. Firefox DriverControls the Firefox browser using aFirefox pluginUses a stripped down profile fromwhat is installed on the machine toonly include the SeleniumWebDriver.xpi (plugin).By default, the Firefox driver createsan anonymous profile 6 www.destinationqa.com
  7. 7. Firefox DriverUsage WebDriver driver = new FirefoxDriver();OS Windows Mac Linux .Versions 3.0, 3.6 5, 6 7, 8 7 www.destinationqa.com
  8. 8. Firefox Driver - Runs in a real - Slower than the browser and HtmlUnit Driver supports JavaScript - Faster than the Internet Explorer Driver 8 www.destinationqa.com
  9. 9. Internet Explorer DriverStructure This driver is controlled by a .dll and is thus only available on Windows OS.Usage WebDriver driver = new InternetExplorerDriver();OS WindowsVersions IE 6, IE 7 and IE 8 on XP IE 9 on Windows7. 9 www.destinationqa.com
  10. 10. Internet Explorer Driver Comparatively slow Runs in a real XPath is not natively browser and supported in most versions. supports JavaScript with Sizzle is injected - Slower all the quirks than other browsers and your end users CSS selectors. see. CSS not natively supported in IE 6 and 7. Sizzle is injected instead. CSS natively supported in IE 8, 9, but doesn’t fully www.destinationqa.com 10
  11. 11. HtmlUnit DriverStructure The fastest and most lightweight of Drivers. Based on HtmlUnit. HtmlUnit is a java based implementation of a WebBrowser without a GUI.Usage WebDriver driver = new HtmlUnitDriver();OS AnyVersions N/A 11 www.destinationqa.com
  12. 12. HtmlUnit Driver Fastest Emulates other implementation of browsers’ WebDriver JavaScript A pure Java solution behaviour and so it is platform independent. Supports JavaScript 12 www.destinationqa.com
  13. 13. Java Script in HtmlUnit HtmlUnit’s Java Script engine (Rhino) is not used by other popular browsers What does this mean?  If web application is tested enabling JS engine of HTMLUnit, the results may be different as compare to other browsers. 13 www.destinationqa.com
  14. 14. Other Drivers Chrome Driver Opera Driver iPhone Driver Android Driver 14 www.destinationqa.com
  15. 15. Thank You…Aparna NaikEmail: naik.aparna@destinationqa.comTel: +91 99233 50980 15 www.destinationqa.com

×