2. Components
• Selenium IDE
• Implemented as a firefox add-on, and allows recording, editing,
and debugging tests. Scripts written in Selenese (special scripting
language)
3. Components
• Selenium IDE
• Implemented as a firefox add-on, and allows recording, editing,
and debugging tests. Scripts written in Selenese (special scripting
language)
• Selenium-client API
• Communicates with Selenese with other programming languages
4. Components
• Selenium IDE
• Implemented as a firefox add-on, and allows recording, editing,
and debugging tests. Scripts written in Selenese (special scripting
language)
• Selenium-client API
• Communicates with Selenese with other programming languages
• Selenium Remote Control
• Server, written in Java, that accepts commands for browser via
HTTP.
5. Components
• Selenium IDE
• Implemented as a firefox add-on, and allows recording, editing,
and debugging tests. Scripts written in Selenese (special scripting
language)
• Selenium-client API
• Communicates with Selenese with other programming languages
• Selenium Remote Control
• Server, written in Java, that accepts commands for browser via
HTTP.
• Selenium Grid
• Server that allows tests to use web browser instances running on
remote machines.
6. Components
• Selenium IDE
• Implemented as a firefox add-on, and allows recording, editing,
and debugging tests. Scripts written in Selenese (special scripting
language)
• Selenium-client API
• Communicates with Selenese with other programming languages
• Selenium Remote Control
• Server, written in Java, that accepts commands for browser via
HTTP.
• Selenium Grid
• Server that allows tests to use web browser instances running on
remote machines.
7. Components
• Selenium IDE
• Implemented as a firefox add-on, and allows recording, editing,
and debugging tests. Scripts written in Selenese (special scripting
language)
• Selenium-client API
• Communicates with Selenese with other programming languages
• Selenium Remote Control
• Server, written in Java, that accepts commands for browser via
HTTP.
• Selenium Grid
• Server that allows tests to use web browser instances running on
remote machines.
• Selenium WebDriver
• Successor to RC, which accepts commands (in Selenese or Client
API) and sends them to browser.
8. RC vs WD
• Work using Java script injection leads to same
origin policy issues. WebDriver overcomes this
limitation by having driver for each browser.
9. RC vs WD
• Work using Java script injection leads to same
origin policy issues. WebDriver overcomes this
limitation by having driver for each browser.
• While executing tests using Selenium RC it is
obvious to have Selenium RC Server between
Application under test & Test Automation Suite.
This methodology of Client Server architecture of
Selenium RC makes it slower then Selenium Web
Driver.
• Redundancy of commands
• RC cannot support headless browser
but WebDriver can.
10. Selenium Grid
• One server acts as the hub
• Tests contact the hub to obtain access to
browser instances
• The hub has a list of servers that provide
access to browser instances (WebDriver
Nodes), and lets tests use these instances.
• Allows running tests in parallel on different
machines
• Useful to spread the load of testing across
several machines, and to run tests in
browsers running on different platforms or
operating systems.
11. Selenium Grid
• One server acts as the hub
• Tests contact the hub to obtain access to
browser instances
• The hub has a list of servers that provide
access to browser instances (WebDriver
Nodes), and lets tests use these instances.
• Allows running tests in parallel on different
machines
• Useful to spread the load of testing across
several machines, and to run tests in
browsers running on different platforms or
operating systems.
12. Selenium WebDriver
• Implemented through a browser-specific driver, which
sends commands to a browser, and retrieves results.
• Most browser drivers actually launch and access a
browser application.
• Open Source – FREE but Powerful
• Rich community, atleast for java
13. Selenium WebDriver
• Implemented through a browser-specific driver, which
sends commands to a browser, and retrieves results.
• Most browser drivers actually launch and access a
browser application.
• Open Source – FREE but Powerful
• Rich community, atleast for java
14. Selenium WebDriver
• Implemented through a browser-specific driver, which
sends commands to a browser, and retrieves results.
• Most browser drivers actually launch and access a
browser application.
• Open Source – FREE but Powerful
• Rich community, atleast for java
15. Selenium WebDriver
• Implemented through a browser-specific driver, which
sends commands to a browser, and retrieves results.
• Most browser drivers actually launch and access a
browser application.
• Open Source – FREE but Powerful
• Rich community, atleast for java
16.
17.
18. WebDriver Highlights
• WebDriver: With vast features where driver covers all the
features and properties of explorers
• WebDriver: Gives us the opportunity to write once and
execute on multiple platforms
• WebDriver: Despite of working on any language or
environment you need not to learn anything new it is just
grab the knowledge and start producing results
19. Did I see RemoteWebDriver?
• You don’t actually use WebDriver, it’s just an interface.
Implementations of it include: InternetExplorerDriver,
Firefox Driver, ChromeDriver, HtmlUnitDriver, and
RemoteWebDriver.
• If you want to use the browser on the machine that is
running the automation, then you can use anything but
RemoteWebDriver.
• RemoteWebDriver requires the selenium-server-
standalone to be running (the others do not). This could
be running on the same machine, or on a “remote one”
• If you want to use grid (which is via a selenium-server
standalone) then you *MUST* use RemoteWebDriver.
20. Maven – Build Tool
• Caution: Maven expects your test file to have "test" in
filename. so change sample.java to sampleTest.java. and also
change corresponding class inside file. That's it. You are
ready to run your tests.
• So, Maven Requires some initial efforts, but now consider, if
you want to change version of your dependencies or
add/remove more dependencies, you don't have to worry
about downloading jars or placing them in correct folder or
add them to your build path. Just update pom.xml and it will
be taken care by Maven.