Selenium introduction and its components:
Selenium
was created by Jason Huggins in 2004. An engineer at ThoughtWorks, he was
working on a web application that required frequent testing. First tool was
named as “JavaScriptTestRunner” later named as “Selenium Core”
- Selenium is a functional automation tool for web applications
- Selenium is an open-source
- Selenium can support multiple languages like HTML, java, python, ruby, Perl, PHP and C#
- Can support multiple browsers like IE, Google Chrome, Mozilla Firefox, Safari and Opera
- Supports the Operating systems like Windows, Linux, and Mac.
Selenium is mainly built-in 4 Components
- Selenium IDE (Integrated Development Environment)
- Selenium RC (Remote Control)
- Selenium WebDriver
- Selenium Grid
Selenium IDE (Integrated Development Environment):
- Selenium IDE is a simple record and playback tool which comes as an add-on for Mozilla Firefox only.
- Test cases written in IDE can be exported in many programming languages like Ruby, Java, C#, etc. Edit and Debug options along with records are also available.
- It is an excellent tool for beginners to understand the syntax of Selenium WebDriver.
Selenium RC
(Remote control):
- Selenium RC (Remote Control) was the first tool of Selenium Suite. Earlier it was known as JavaScript Executor. RC was the tool which made Selenium famous in the market.
- It was the first tool which provided the support for multiple programming languages (JAVA, Ruby, Perl, PHP, Python, and C#).
- It also supported Browsers like Mozilla Firefox, Google Chrome, Internet Explorer. All the browsers which support JavaScript can be automated using this tool.
- Selenium RC is also known as Selenium 1
Architecture of Selenium RC:
In Selenium
RC, there is a manual process called Selenium Server is mandatory to
start before execution and stop after the execution, which acts as a middleman between the code and the browser.
The commands
(API) are sent to Server. It interprets the command and converts it into
JavaScript and then JavaScript is injected to the browser. Now the browser
executes the javascript and responds to a server, which again interprets the
command and returns to code in the respective language.
Selenium WebDriver:
Selenium
WebDriver is the most important tool of the Selenium suite. Because of the many
limitations with RC, WebDriver was developed. It does not require any manual
process like the Selenium Server. There is direct communication between code and
browser.
Features of
Selenium WebDriver:
- Supports all the key vendors of the browser like Mozilla Firefox, Internet Explorer, Google Chrome, Safari, etc.
- Support Multiple languages like C#, JAVA, Ruby, Perl, Python, and PHP.
- Supports multiple platforms like Linux, Windows, MAC, etc.
- No middleman like the Selenium RC server is required.
- Easy to remember API’s.
- Easy to integrate with testing frameworks.
- Framework Development.
- Parallel Testing capabilities
Selenium Grid:
Selenium
Grid used for parallel testing or distributive testing. It allows us to execute
test scripts on different machines at the same time.
There is a
Hub which controls the execution on various machines, and there are multiple
nodes on which actual implementation is done.
Features of
the Grid:
- Parallel Execution on multiple nodes
- Platform Independent, support almost all Operating System
- Language Independent.
- Browser Independent supports multiple browsers at the same time.
- Fast Execution reduces the execution time as test cases are executed parallelly.
Selenium Grid Architecture
Watch my session on Selenium:
Comments
Post a Comment