Tuesday, 21 February 2017

Automation Testing : Why we go for Automation ?




What is "Automated Testing" ?

Testing an application with third party software help or Automation Tool is called Automation testing.
or
Converting manual test cases into Automation Scripts (in form of code) is called Automation Testing.
  • Automation Testing is automating the manual testing process currently in use.
  • This require that a formalized "Manual Testing process" currently exists in your company
Minimally, such a process includes :
  1. Detailed test cases, including predictable "expected results".(test cases must be documented)
  2. A standalone Test Environment, including a Test Database, such that the test cases are able to be repeated each time there are modifications made to the applications.
If your current testing process does not include the above points, you are never going to be able to make any effective use of an Automated test tool.
  • The real use and purpose of automated test tools is to automate regression testing.
  • This means that you must have or must develop a database of detailed test cases that are ensure that the change does not produce unintended consequences(errors)
  • An "automated test scripts" is a program.
  • Automated Script development, to be effective must be subject to the same rules and standards that are applied to software development.
  • An "automated test suite" is a database of all detailed Automation test cases.
Why we go for Automation ?

Testing an application with human interaction is called Manual Testing. Manual testing is always a priority but there are some problems in manual testing.
  • No Reusability
  • More Resources required
  • Time consuming
  • Budget is high
  • Human errors causes poor quality
Benefits of Automation Testing :
  • Fast : Automation tool runs tests significantly faster than human users.
  • Reliable : Automation tool can perform the same operations each time, if you repeated multiple times, so that we can eliminate human errors.
  • Repeatable : We can check how application and website react after repeated the same operation with multiple times.
  • Reusable : Automation scripts reusable on different version of the application of websites even if the user interfaces changes.
  • Comprehensive : In Automation testing we can build a suit of tests that covers every feature in the application or website.
  • Programmable : We can program sophisticated Test that brings out hidden information from the application.

Monday, 13 February 2017

Major Difference Between Selenium and QTP

When we talk about automation testing, so we have to more like company have to decide which automation tool will gonna use. Company decide tool based on the cost of project, which tool suites client fulfillment etc.

Selenium and QTP are widely used testing tools used in current market. But because Selenium is free testing tool, it is used mostly.


So, Here are the major difference between Selenium and QTP :-




Properties
Selenium
QTP
Cost
It is an Open source tool.
It is a Paid tool.
OS Compatibility
Selenium works on all Operating Systems (Windows, OS X, Linux, Solaris, and Mac).
It works only on Windows.
Application Type
Tests only Web applications
Tests web and desktop applications
Browser Compatibility
Works on almost all browsers (IE, Firefox, Chrome, Safari, Opera).
Works on IE
Language
Code can be made in any one of languages such as Java, C#, Ruby, Python, pearl, php etc.
Code only made in VB Script.
Element Locator
Objects will identify by using HTML ID, name, Xpath, CSS, DOM and Link text.
Objects will identify by using Object properties, Repository objects.
Object Repository
Selenium does not have such built in object repository , but object can be managed by using UI element user extension like Firebug & firepath.
HP UFT comes with built in object repository. Object repository development and maintenance is quite easy in HP ALM.
Recording
IDE sometimes does not record some events.
Recording is a little reliable.
Storage
Set of Libraries, around 20MB (Need to include other supporting software).
Around 1.5GB
Maintenance and support
Saucelabs.com, Elements34, Commercial Supports.(no official support)
From HP

Friday, 10 February 2017

What is Selenium ?

 

History of Selenium :

  •  In 2004 invented by Jason Huggins and team.
  • Original name is JavaScript Functional Tester (JSFT).
  • Open source browser based integration framework (Selenium RC) built originally by Thought Works.
  • Google, who has been a long time user of Selenium, had a developer named Simon Stewart who developed WebDriver. This tool circumvented Selenium's JavaScript sandbox to allow it to communicate with the Browser and Operating System directly using native methods.
  • In 2008, Selenium and WebDriver merged technologies and intellectual intelligence to provide the best possible test automation framework.

 

What is Selenium ? :


"Selenium is one API having a group of components."
Selenium is a free (open source) automated testing suite for web applications across different browsers and platforms. It is quite similar to HP Quick Test Pro (QTP) only that Selenium focuses on automating web-based applications. It is 100% JavaScript and HTML Web Testing Tool which supports for cross-Browser testing (On Multiple browsers) and multiple operating systems.
Selenium is not just a single tool but a suite of software, each catering to different testing needs of an organization. It has five components.

 

Selenium Components :-

  • Selenium IDE (Integrated Development Environment) - Record and Playback
  • Selenium Core - Runs the test suits on the web server where the web application is deployed
  • Selenium RC - 1.0 - Server / Client (Selenium. Start/Selenium. Stop)
  • Selenium 2.0 / WebDriver / Advanced Selenium
  • Selenium Grid - Performance Tool
Selenium Components

Sunday, 5 February 2017

Testing_128 : Guidelines & checklist for Web Testing

 

Purpose :

World web is browsed by customers with different knowledge levels, while testing websites (static/dynamic). A dept should concentrate on various aspects to make effective presentation of website in www.

Aspects to Cover :
  • Functionality 
  • Usability
  • User Interface
  • Database
  • Compatibility
  • Security
  • Performance
  • Server Log Files 

 

1. Functionality :


1.1 Links :-

Objective is to check for all the links in the website
  • All Hyperlinks, All Internal Links, All External Links, All Mail Links, Image Links.
  • Check that the link takes you to the page it said it would. 
  • Check all of your links to other websites.
  • Are all referenced web sites or email addresses hyperlinked ? 
  • Check all the links that would pointing to right environment.
1.2 Forms/Screen :-

Check for the integrity of submission of all forms
  • All field level checks
  • All field level validations
  • Functionality of [Submit], [update], [view]
  • Handling of wrong inputs
  • Default value if any (standard)
  • Optional versus Mandatory fields.
  • Radio buttons
  • Is all the data inside combo/list box are arranged in proper order ?
  • Are all of the parts of a table or form present ? Correctly laid out ?
  • Does a scrollbar appear if required ?
1.3 Database :-

Verify whether the operations performed from front end to back end or not.
Two types of errors that may occur in web application
Data integrity : Missing or wrong data in table.
Output Errors : Errors in writing, Editing or reading operation in the table
  • Check the maximum field lengths to ensure that there are no truncated characters ?
  • If numeric fields accept negative values can these be stored correctly on the database and does it make sense for the field to accept negative numbers ?
  • If a particular set of data is saved to the database check that each value gets saved fully to the database. (i.e.) Beware of truncation (of strings) and rounding of numeric values.

 

2. Usability :


How Simple customer can browse or user friendliness.

2.1 Navigation :-

Navigation describes the way user navigates with in a webpages, between user interface controls (Buttons, text boxes, combo boxes and dropdown lists etc.).
  • Application navigation is proper through tab.
  • Application navigation through mouse.
  • Main features accessible from the main/home page (mother window)
  • Any-hot keys, control keys to access menu.
2.2 Contents :-

Correctness is whether the information is truthful the accuracy of the information is whether it is without grammatical or spelling errors. Remove irrelevant information from your site this may otherwise cause.
  • Spelling & Grammer
  • Updated information
  • Background/Foreground
  • Tools tip message
  • Mouse over message 

 

3. User Interface :


All about exactly website looks like (view)

Basic Guidelines for web User Interface 
  • Every dropdown box should have the first choice as NONE (it could be any other meaningful sentence such as 'choose one' or 'select')
  • Horizontal Scrolling is not preferable in general. Avoid using horizontal scroll bar ensure that the use of vertical scroll bar is judicious.
  • Illegal operations should give POP UP messages (messages should be simple and clear).
  • Positive POP UP messages should be displayed (Submitted, deleted, updated, done, cleared).
  • Avoid long scrolling dropdown list make it short.

 

4. Compatibility:


4.1 Platforms :- 

Check for the website compatibility with
  • Windows
  • UNIX
  • Linux
  • Macintosh (if applicable).
4.2 Browser :-
  • Internet Explorer
  • AOL
  • Firefox
  • Safari
  • Google Chrome

 

5. Security :

  • Valid & invalid Login.
  • Limits defined for the no. of tries.
  • Can it be bypassed by typing URL to a page inside directly in the browser?
  • Secure pages should use HTTPS protocol.
  • Test password security and password policy enforcement.
  • Check application logout functionality.
  • Cookie information should be stored in encrypted format only.
  • Check session cookie duration and session termination after timeout or logout.
  • Verify the log files are maintained to store the information for traceability.
  • Verify encryption is done correctly if SSL (SSL Certificate vendors VeriSign GeoTrust, SSL.com etc.) is used (if applicable).
  • No access to edit scripts on the server without authorization.
  • If Webpages is idle for 10 to 15 Minutes, session will expire.

 

6. Performance :


6.1 Connection Speed :-
  • Try with different connection speed.
6.2 Load :-
  • Will there be peak loads & how systems react.
  • Can your site handle a large amount of users requesting a certain page.
6.3 Stress :-
  • Stress testing is done in order to actually break a site or certain features to determine how the system reacts.
  • Stress tests are designed to push & test system limitations & determine whether the system recovers gracefully from crashes.
  • Check if page load time is within acceptable range.
  • Check page load on slow connections.
  • Check response time for any action under light, normal , moderate and heavy load conditions.
  • Check performance of database stored procedures and triggers.
  • Check database query execution time.
  • Check for load testing of application.
  • Check for stress testing of application.
  • Check CPU and memory usage under peak load condition.

 

7. Server Log Files Testing :


For Every client request to the server, server side client information will be stored automatically in the form of logs.
Log Contain :-
  • Client Request
  • Server response
  • Data/Time of request
  • Client IP address
There are 4 normal levels of logger available

Static Level INFO:
The INFO Level designates informational messages that highlight the progress of the application.

Static Level WARN:
The WARN Level designates potentially harmful situations.

Static Level ERROR:
The ERROR Level designates potentially errors events that might still allow the application to continue running.

Static Level FATAL:
The FATAL Level designates very severe error events that will presumably lead the application.