Overview on Selenium
I) Introducing Selenium
Selenium Tool's suite is Mainly used for Functional together with Regression Testing of Web Applications.
It is Open beginning software to automate Browsers, way it is precisely for automating spider web applications, It doesn’t back upward Desktop applications. UFT examine tool supports Desktop together with spider web applications.
Selenium is a laid of dissimilar software tools each amongst a dissimilar approach to supporting examine automation.
It is non a unmarried tool similar UFT, RFT, SilkTest etc…
Selenium QA Engineers focus on the i or 2 tools that run across the needs of their project.
Learning all the tools volition give us many dissimilar options for approaching dissimilar examine automation problems.
Selenium Supports diverse programming together with scripting Languages for applying programming logic to our Tests.
It Supports:
Java, C#, Perl, Python, Ruby together with PHP Languages, most of the companies usage Java Language, So you lot also seek to usage Java Language.
Why Java only? Why can’t nosotros usage other languages, most of the supporting together with assistance documentation together with implementations available on Internet inwards Java only, if nosotros usage or thence other languages thence back upward is rattling less.
II) History of the Selenium Project:
Selenium starting fourth dimension came to life inwards 2004 when Jason Huggins was testing an internal application at ThoughtWorks.
He developed a Javascript library that could drive interactions amongst the page, allowing him to automatically rerun tests against multiple browsers.
In 2006 an engineer at Google named Simon Stewart started piece of occupation on a projection he called WebDriver.
In 2008, the whole Selenium Team decided to merge WebDriver together with Selenium RC to shape a to a greater extent than powerful tool called Selenium 2.
Selenium RC is nonetheless beingness developed but precisely for maintenance.
III) Selenium License:
All Selenium projects are licensed nether the Apache 2.0 License, but It is Open beginning anybody tin post away download together with usage selenium suite(Selenium IDE, Selenium RC, Selenium WebDriver together with Selenium Grid) of tools amongst costless of cost.
IV) Selenium Supporting Platforms / Environments:
a) Operating Systems:
Microsoft Windows
• Windows XP (supported ended Apr 8, 2014)
• Windows 7
• Windows 8
• Windows 8.1
Linux
Macintosh Etc…
Apple OS X
b) Browsers:
• Mozilla
• Internet Explorer
• Chrome
• Safari
• Opera
c) Scripting/Programming:
• Java
• C#
• Javascript
• Perl
• Python
• PHP
• Ruby
d) Software Applications
• CUI based Applications (* It doesn't support)
• Desktop Applications (I-Tier together with II-tier Applications) (* It doesn't support)
• Web Applications (It Supports)
• Mobile Applications (*Which bring spider web forms) (It supports)
V) Selenium Suite of Tools
Selenium is composed of multiple software tools. Each has a specific role.
Selenium 2 is the futurity administration of the projection together with the newest add-on to the Selenium toolkit.
Selenium 2.0 is the production of that effort. It supports the WebDriver API. In addition, Selenium 2 nonetheless runs Selenium 1’s Selenium RC interface for backwards compatibility.
Selenium RC was the primary Selenium projection for a long time, earlier the WebDriver/Selenium merge brought upward Selenium 2.
a) Selenium IDE:
Selenium IDE, IDE stands for Integrated Development Environment is a tool for edifice examine scripts. It is a Firefox plugin together with provides an easy-to-use interface for developing automated tests.
Selenium IDE has a recording feature, which records user actions equally they are performed on AUT together with thence exports them equally a reusable script inwards i of many programming languages that tin post away live subsequently executed.
Features of Selenium IDE:
• Record together with Play dorsum Test Cases
• Exporting Test Cases to dissimilar Languages
Disadvantages of Selenium IDE:
• It supports Mozilla Firefox Browser only.
• Data Driven Testing (executing tests using mulpiple sets of examine data) is non possible.
• Test Results are non generated using Selenium IDE (It generats summary only).
• Random Test Cases execution is non possible
• Selenium IDE doesn’t back upward Flow command Statements.
b) Selenium RC
Selenium RC solves the limitations of Selenium IDE. It supports diverse programming languages similar Java, C#, PHP, Perl, Python together with Ruby languages to attain logic required inwards examine cases similar conditional statements, iterations, exception handling, examine reporting, database testing, capturing covert shots of failed tests, examine illustration grouping etc...
Important advantages of Selenium RC:
• It supports Random Test cases execution
• Supports Flow command statements together with other programming features to heighten Tests.
• Supports diverse Browsers for Tests execution.
Disadvantage of Selenium RC:
• Test Case execution fourth dimension is to a greater extent than because every customer asking starting fourth dimension post to Selenium Server after that post to Browser.
• Executing Tests inwards parallel is non possible.
c) Selenium WebDriver
The biggest alter inwards Selenium latterly has been the inclusion of the WebDriver API. Selenium WebDriver fits inwards the same role equally RC did.
WebDriver is designed inwards a simpler together with to a greater extent than concise programming interface along amongst addressing or thence limitations inwards the Selenium-RC API.
WebDriver overcomes the limitation of Selenium RC (Remote Control)
Selenium-WebDriver supports the next browsers along amongst the operating systems these browsers are compatible with.
• Google Chrome
• Internet Explorer 6, 7, 8, 9, 10 - 32 together with 64-bit where applicable
• Firefox: latest ESR, previous ESR, electrical flow release, i previous release
• Safari
• Opera
• HtmlUnit
• phantomjs
• Android (with Selendroid or appium)
• iOS (with ios-driver or appium)
d) Selenium Grid
Selenium-Grid allows the Selenium RC solution to scale for large examine suites together with for examine suites that must live run inwards multiple environments.
Selenium Grid allows you lot to run your tests inwards parallel, that is, dissimilar tests tin post away live run at the same fourth dimension on dissimilar remote machines.
VI) Selenium versus UFT
HP UFT (Formerly QTP) is a unmarried Tool together with VBScript engine integrated.
Selenium is Suite of Tools (Selenium IDE, Selenium RC, WebDriver together with Selenium Grid). VII) Advantages of Selenium
• Since It is an Open beginning Software (free tool), anybody tin post away downwardly charge together with usage amongst costless of cost, it oftentimes is i of the few options for companies that practice non bring a lot of budget for Automation tools.
• Selenium was starting fourth dimension written inwards Java but it also supports C#, Ruby, Perl, PHP together with Python. This is a large plus when nosotros desire to construct our framework inwards a linguistic communication that has the highest adoption inwards the organisation it is beingness built within. Tools similar UFT / QTP forcefulness you lot to usage VBScript – which is almost never the preferred scripting linguistic communication for developers.
• It has back upward for all of the pop browsers similar IE, Firefox, Chrome, Safari etc. It also supports several Operating Systems together with that makes it a tool of alternative for cross browser/ cross platform certification.
• Once you lot conk Selenium to piece of occupation for you, it plant reliably when used for running the tests over together with over again. It’s definitely a lot to a greater extent than reliable than tools similar QEngine or JExplorer but close the same equally tools similar UFT / QTP.
• You tin post away instantiate several concurrent tests amongst Selenium Grid.
VIII) Disadvantages of Selenium:
• Supports Web based (Browser based) Application only, doesn't back upward Desktop or standalone Application examine automation.
• Since it is Open beginning software, no reliable technical back upward from anybody.
• Some novel features may or may non piece of occupation properly.
• Deploying Selenium Tool is hard than UFT (Formerly QTP) Tool.
IX) Selenium Certification:
Since it is opened upward beginning software, No Authorized Certification for Selenium Tool, or thence organizations are conducting Selenium certification examination but no value guaranty for them inwards the information technology Industry.
X) Testing Frameworks Used inwards Selenium
a) JUnit
Junit is a framework for unit of measurement testing, together with It tin post away live used for Selenium functional tests also.
Many frameworks similar Data Driven Framework, Keyword Driven Framework, together with Hybrid Framework which usage Junit tool equally examine runner.
JNunit volition assistance to execute Test Batches together with generating Reports.
b) TestNG
TestNG is a tool /framework that helps us to organize the tests together with generate the examine reports.
TestNG framework tin post away live used for automation testing amongst Selenium.
TestNG has built inwards HTML study together with XML study generation facility. It has also built in logging facility.
XI) Choosing Selenium Tool
If you lot are non already experienced amongst a programming or scripting linguistic communication thence you lot tin post away usage Selenium IDE to conk familiar amongst Selenium commands.
Using the IDE you lot tin post away create elementary tests quickly.
It is non recomended you lot practice all your examine automation using Selenium IDE. To effectively usage Selenium you lot volition require to construct together with run your tests using either Selenium 2
Try to usage Selenium WebDriver for effective Test automation if you lot bring programming or scripting knowledge.
XII) Configure Selenium
After Selecting selenium Tools thence configure,
Suppose nosotros selected Java for programming together with WebDriver for generating together with executing Tests, Firebug for inspecting Objects.
-> Install Java
-> Install Eclipse (IDE for Java)
-> Install Firebug equally Firefox plug in.
-> Download WebDriver Interface from Seleniumhq website together with deploy inwards Eclipse.
------------------------------
Also Read:
Selenium Interview Questions
Selenium WebDriver
Selenium Online Training
I) Introducing Selenium
Selenium Tool's suite is Mainly used for Functional together with Regression Testing of Web Applications.
It is Open beginning software to automate Browsers, way it is precisely for automating spider web applications, It doesn’t back upward Desktop applications. UFT examine tool supports Desktop together with spider web applications.
Selenium is a laid of dissimilar software tools each amongst a dissimilar approach to supporting examine automation.
It is non a unmarried tool similar UFT, RFT, SilkTest etc…
Selenium QA Engineers focus on the i or 2 tools that run across the needs of their project.
Learning all the tools volition give us many dissimilar options for approaching dissimilar examine automation problems.
Selenium Supports diverse programming together with scripting Languages for applying programming logic to our Tests.
It Supports:
Java, C#, Perl, Python, Ruby together with PHP Languages, most of the companies usage Java Language, So you lot also seek to usage Java Language.
Why Java only? Why can’t nosotros usage other languages, most of the supporting together with assistance documentation together with implementations available on Internet inwards Java only, if nosotros usage or thence other languages thence back upward is rattling less.
II) History of the Selenium Project:
Selenium starting fourth dimension came to life inwards 2004 when Jason Huggins was testing an internal application at ThoughtWorks.
He developed a Javascript library that could drive interactions amongst the page, allowing him to automatically rerun tests against multiple browsers.
In 2006 an engineer at Google named Simon Stewart started piece of occupation on a projection he called WebDriver.
In 2008, the whole Selenium Team decided to merge WebDriver together with Selenium RC to shape a to a greater extent than powerful tool called Selenium 2.
Selenium RC is nonetheless beingness developed but precisely for maintenance.
III) Selenium License:
All Selenium projects are licensed nether the Apache 2.0 License, but It is Open beginning anybody tin post away download together with usage selenium suite(Selenium IDE, Selenium RC, Selenium WebDriver together with Selenium Grid) of tools amongst costless of cost.
IV) Selenium Supporting Platforms / Environments:
a) Operating Systems:
Microsoft Windows
• Windows XP (supported ended Apr 8, 2014)
• Windows 7
• Windows 8
• Windows 8.1
Linux
Macintosh Etc…
Apple OS X
b) Browsers:
• Mozilla
• Internet Explorer
• Chrome
• Safari
• Opera
c) Scripting/Programming:
• Java
• C#
• Javascript
• Perl
• Python
• PHP
• Ruby
d) Software Applications
• CUI based Applications (* It doesn't support)
• Desktop Applications (I-Tier together with II-tier Applications) (* It doesn't support)
• Web Applications (It Supports)
• Mobile Applications (*Which bring spider web forms) (It supports)
V) Selenium Suite of Tools
Selenium is composed of multiple software tools. Each has a specific role.
Selenium 2 is the futurity administration of the projection together with the newest add-on to the Selenium toolkit.
Selenium 2.0 is the production of that effort. It supports the WebDriver API. In addition, Selenium 2 nonetheless runs Selenium 1’s Selenium RC interface for backwards compatibility.
Selenium RC was the primary Selenium projection for a long time, earlier the WebDriver/Selenium merge brought upward Selenium 2.
a) Selenium IDE:
Selenium IDE, IDE stands for Integrated Development Environment is a tool for edifice examine scripts. It is a Firefox plugin together with provides an easy-to-use interface for developing automated tests.
Selenium IDE has a recording feature, which records user actions equally they are performed on AUT together with thence exports them equally a reusable script inwards i of many programming languages that tin post away live subsequently executed.
Features of Selenium IDE:
• Record together with Play dorsum Test Cases
• Exporting Test Cases to dissimilar Languages
Disadvantages of Selenium IDE:
• It supports Mozilla Firefox Browser only.
• Data Driven Testing (executing tests using mulpiple sets of examine data) is non possible.
• Test Results are non generated using Selenium IDE (It generats summary only).
• Random Test Cases execution is non possible
• Selenium IDE doesn’t back upward Flow command Statements.
b) Selenium RC
Selenium RC solves the limitations of Selenium IDE. It supports diverse programming languages similar Java, C#, PHP, Perl, Python together with Ruby languages to attain logic required inwards examine cases similar conditional statements, iterations, exception handling, examine reporting, database testing, capturing covert shots of failed tests, examine illustration grouping etc...
Important advantages of Selenium RC:
• It supports Random Test cases execution
• Supports Flow command statements together with other programming features to heighten Tests.
• Supports diverse Browsers for Tests execution.
Disadvantage of Selenium RC:
• Test Case execution fourth dimension is to a greater extent than because every customer asking starting fourth dimension post to Selenium Server after that post to Browser.
• Executing Tests inwards parallel is non possible.
c) Selenium WebDriver
The biggest alter inwards Selenium latterly has been the inclusion of the WebDriver API. Selenium WebDriver fits inwards the same role equally RC did.
WebDriver is designed inwards a simpler together with to a greater extent than concise programming interface along amongst addressing or thence limitations inwards the Selenium-RC API.
WebDriver overcomes the limitation of Selenium RC (Remote Control)
Selenium-WebDriver supports the next browsers along amongst the operating systems these browsers are compatible with.
• Google Chrome
• Internet Explorer 6, 7, 8, 9, 10 - 32 together with 64-bit where applicable
• Firefox: latest ESR, previous ESR, electrical flow release, i previous release
• Safari
• Opera
• HtmlUnit
• phantomjs
• Android (with Selendroid or appium)
• iOS (with ios-driver or appium)
d) Selenium Grid
Selenium-Grid allows the Selenium RC solution to scale for large examine suites together with for examine suites that must live run inwards multiple environments.
Selenium Grid allows you lot to run your tests inwards parallel, that is, dissimilar tests tin post away live run at the same fourth dimension on dissimilar remote machines.
VI) Selenium versus UFT
UFT | Selenium |
1) UFT is a Single Tool supports Test Automation. | Selenium is a suite of Tools, supports Test Automation. |
2) Unified Functional Testing is a Vendor Tool, Vendor is HP. | Selenium is an Open beginning software released nether Apache 2.0 License (Free to use) |
3) UFT Supports Test Automation for Desktop applications together with Web Applications. | Selenium Supports Test Automation for Web Applications only. |
4) UFT supports VBScript for applying programming features to Tests. | Selenium supports Java, C#, Perl, Python, Ruby together with PHP to heighten Tests. |
5) Automation toll is expensive due to license cost. | Since it is Open beginning software, Automation toll is inexpensive. |
6) Since It is Vendor Tool, nosotros tin post away conk reliable technical back upward from the vendor (HP). | Since it is Open beginning software at that topographic point is no reliable Technical support. |
7) UFT is user friendly, Tests tin post away live developed quickly. | Tests require to a greater extent than fourth dimension to railroad train together with maintain. |
8) Tests tin post away live easily execute on latest version of UFT Tool also. | Tests require to live updated due to novel API changes inwards latest versions. |
9) UFT integrates amongst ALM / Quality optic (Test administration Tool). | There is no tool that integrates amongst Selenium. |
10) New features volition piece of occupation properly together with Knowledge sharing is easy. | New Features may non piece of occupation properly together with Knowledge sharing is difficult. |
11) UFT supports Windows operating surroundings only. It doesn't back upward other operating environments similar UNIX together with Mac. | Selenium supports Windows, UNIX together with Mac operating environments. |
12) Image based tests are slowly inwards UFT. | Image based Tests are possible but difficult. |
13) UFT uses to a greater extent than hardware resources. | Selenium uses less hardware resources. |
14) UFT has authorized Certification program. | There is no authorized Certification Program. |
HP UFT (Formerly QTP) is a unmarried Tool together with VBScript engine integrated.
Selenium is Suite of Tools (Selenium IDE, Selenium RC, WebDriver together with Selenium Grid).
• Since It is an Open beginning Software (free tool), anybody tin post away downwardly charge together with usage amongst costless of cost, it oftentimes is i of the few options for companies that practice non bring a lot of budget for Automation tools.
• Selenium was starting fourth dimension written inwards Java but it also supports C#, Ruby, Perl, PHP together with Python. This is a large plus when nosotros desire to construct our framework inwards a linguistic communication that has the highest adoption inwards the organisation it is beingness built within. Tools similar UFT / QTP forcefulness you lot to usage VBScript – which is almost never the preferred scripting linguistic communication for developers.
• It has back upward for all of the pop browsers similar IE, Firefox, Chrome, Safari etc. It also supports several Operating Systems together with that makes it a tool of alternative for cross browser/ cross platform certification.
• Once you lot conk Selenium to piece of occupation for you, it plant reliably when used for running the tests over together with over again. It’s definitely a lot to a greater extent than reliable than tools similar QEngine or JExplorer but close the same equally tools similar UFT / QTP.
• You tin post away instantiate several concurrent tests amongst Selenium Grid.
VIII) Disadvantages of Selenium:
• Supports Web based (Browser based) Application only, doesn't back upward Desktop or standalone Application examine automation.
• Since it is Open beginning software, no reliable technical back upward from anybody.
• Some novel features may or may non piece of occupation properly.
• Deploying Selenium Tool is hard than UFT (Formerly QTP) Tool.
IX) Selenium Certification:
Since it is opened upward beginning software, No Authorized Certification for Selenium Tool, or thence organizations are conducting Selenium certification examination but no value guaranty for them inwards the information technology Industry.
X) Testing Frameworks Used inwards Selenium
a) JUnit
Junit is a framework for unit of measurement testing, together with It tin post away live used for Selenium functional tests also.
Many frameworks similar Data Driven Framework, Keyword Driven Framework, together with Hybrid Framework which usage Junit tool equally examine runner.
JNunit volition assistance to execute Test Batches together with generating Reports.
b) TestNG
TestNG is a tool /framework that helps us to organize the tests together with generate the examine reports.
TestNG framework tin post away live used for automation testing amongst Selenium.
TestNG has built inwards HTML study together with XML study generation facility. It has also built in logging facility.
XI) Choosing Selenium Tool
If you lot are non already experienced amongst a programming or scripting linguistic communication thence you lot tin post away usage Selenium IDE to conk familiar amongst Selenium commands.
Using the IDE you lot tin post away create elementary tests quickly.
It is non recomended you lot practice all your examine automation using Selenium IDE. To effectively usage Selenium you lot volition require to construct together with run your tests using either Selenium 2
Try to usage Selenium WebDriver for effective Test automation if you lot bring programming or scripting knowledge.
XII) Configure Selenium
After Selecting selenium Tools thence configure,
Suppose nosotros selected Java for programming together with WebDriver for generating together with executing Tests, Firebug for inspecting Objects.
-> Install Java
-> Install Eclipse (IDE for Java)
-> Install Firebug equally Firefox plug in.
-> Download WebDriver Interface from Seleniumhq website together with deploy inwards Eclipse.
------------------------------
Also Read:
Selenium Interview Questions
Selenium WebDriver
Selenium Online Training