Automation Testing: by Balaji
Automation Testing: by Balaji
TESTING
By
Balaji
1
INTRODUCTION
Executing the test cases manually without any tool
support is known as manual testing.
Taking tool support and executing the test cases by
using automation tool is known as automation
testing.
2
DIFFERENCE B/W MANUAL & AUTOMATION
Following table shows the difference between manual testing and
automation testing.
3
DIFFERENCE B/W MANUAL & AUTOMATION
4. Non-programmable: No
4. Programmable: Testers can program
programming can be done to write
sophisticated tests to bring out hidden
sophisticated tests which fetch hidden
information.
information.
4
WHY AUTOMATION
Test automation has specific advantages for improving the long-term
efficiency of a software team’s testing processes. Test automation supports:
Frequent regression testing
Rapid feedback to developers
Virtually unlimited iterations of test case execution
Support for Agile and extreme development methodologies
Disciplined documentation of test cases
Customized defect reporting
Finding defects missed by manual testing
5
BENEFITS OF AUTOMATION TESTING
Fast: Runs tests significantly faster than human users.
Repeatable: Testers can test how the website or software
reacts after repeated execution of the same operation.
Reusable: Tests can be re-used on different versions of the
software.
Reliable: Tests perform precisely the same operation each
time they are run thereby eliminating human error.
Comprehensive: Testers can build test suites of tests that
covers every feature in software software application.
Programmable: Testers can program sophisticated tests that
bring hidden information.
6
TEST AUTOMATION TOOLS
7
WHY WE CHOOSE SELENIUM
8
HISTORY
2004 - at ThoughtWorks in Chicago, Jason Huggins built the Core mode as
"JavaScriptTestRunner" for the testing of an internal Time and Expenses application
(Python, Plone).
2006 - at Google, Simon Stewart started work on a project he called WebDriver. Google
had long been a heavy user of Selenium, but testers had to work around the limitations of
the product.The WebDriver project began with the aim to solve the Selenium’ pain-
points.
2008 - merging of Selenium and WebDriver. Selenium had massive community and
commercial support, but WebDriver was clearly the tool of the future. The joining of the
two tools provided a common set of features for all users and brought some of the
brightest minds in test automation under one roof.
Shinya Kasatani in Japan became interested in Selenium, he
Wrapped the core code into an IDE module into the Firefox browser
Added the ability to record tests as well as play them back in the same plugin.
This tool, turned out an eye opener in more ways that was originally thought as it is not bound to the same
origin policy.
9
SELENIUM WORLD
10
SELENIUM IDE – LIMITATIONS/DRAWBACKS
Firefox only
Can not Specify any condition Statement.
Can not Specify any Looping Statement.
Can not take external text data from External Resources
such as XLS,XML or Database.
Handing Exceptions is not in scope.
Note:- To overcome the limitation of Selenium IDE we go
for Selenium WebDriver.
11
SELENIUM WEB DRIVER
12
SELENIUM WEB DRIVER – BROWSER
SUPPORTHAT IS SELENIUM
Selenium-WebDriver supports the following browsers along with the
operating systems these browsers are compatible with.
Google Chrome
Internet Explorer
Firefox
Opera 11.5+
HtmlUnit
Android – 2.3+ for phones and tablets (devices & emulators)
iOS 3+ for phones (devices & emulators) and 3.2+ for tablets (devices & emulators)
13
WEBDRIVER &
SELENIUM-SERVER
Some reasons to use the Selenium-Server with Selenium-
WebDriver.
You are using Selenium-Grid to distribute your tests over
multiple machines or virtual machines (VMs).
You want to connect to a remote machine that has a
particular browser version that is not on your current
machine.
You are not using the Java bindings (i.e. Python, C#, or Ruby)
and would like to use HtmlUnit Driver
14
INSTALL/CONFIGURE WEBDRIVER WITH
ECLIPSE
15
INSTALL/CONFIGURE WEBDRIVER WITH
ECLIPSE
16
SIMPLE ARCHITECTURE OF WEBDRIVER
Interface
WEBDRIVER(i)
Internet Explorer
Firefox Driver Chrome Driver
Driver