Understanding Software Testing And Types
Introduction
Testing is a mechanism to verify and validate the “System in consideration is performing as per the requirements and is available to its intended users when its suppose to be”.
This ensures that the targeted system is defect free which never is possible that's why testing is a forever going process.
Categories of Software Testing
Testing can be performed either knowing all of the underlying source code or without having any idea about the architecture or how things are handled by the system. Based upon the notion, the software testing is divided into two categories, namely “Black-Box” and “White-Box” testing.
(I) Black-Box Testing
Black box testing is also called “closed testing” as the person who is testing the system is not aware of the source code or any of the architectural details the software is comprised of and just focused upon the correct behavior of the System at test.
Black box testing is divided in to following types.
(1) Functional.
(2) Non Functional.
(3) Regression.
(II) White-Box Testing
White box testing is also called “clear box testing” as the person who is testing the system is aware of the source code and the architectural details of the particular area of the System at test.
White box testing is divided in to following types.
(1) Unit Testing.
(2) Integration Testing.
Journey of Testing
Testing starts with the project proposal and continues throughout the software life and till the moment it no longer exist.
The journey can be defined in the below steps.
(1) Unit testing of each functionality.
(2) Integration testing of two or more modules.
(3) System testing of the entire solution.
(4) Performance testing of the system.
(5) User acceptance testing of the system user interface and its functionalities.
(∞) Repetition of above steps.
Testing Types Overview
(1) Unit Testing
Unit testing is performed at code level for each and every module to identify errors and bugs during the development process.
It is divided into three types.
(i) Operation Testing.
(ii) Mutation Testing.
(iii) Execution Testing.
(i) Operation Testing
Operation testing is about testing the non functional aspect of the system. i.e. Performance testing, User Experience testing, Usability testing etc. .
(ii) Mutation Testing
Mutation testing is about testing the module by making small changes in it to verify the tests are able to find the bugs and errors.
(iii) Execution Testing
Execution testing is about testing the functionality of the module with all possible permutations of input.
This can be done through many approaches such as following.
- Statement Coverage: All the statements inside the module are tested at least once.
- Branch Coverage: All the branches (conditional loops) inside the module are tested at least once.
- Path Coverage: All the paths (statements + branches) inside the module are tested.
(2) Integration Testing
Integration testing is focused upon how two or more modules are functioning together and are there possible glitches in the system when certain permutation of data is supplied. These are performed with the help of “Stubs and Drivers”.
Stub is a dummy module which is being called by a parent module.
Driver is a dummy module which calls a parent module.Integration testing is divided into four approaches.
(i) Top Down Approach.
(ii) Bottom Up Approach.
(iii) Big Bang Approach.
(iv) Hybrid Integration Approach.
(i) Top Down Approach
In this approach, modules are testing in the ascending manner. For example the module “Parent” is tested with module “child1”. If the module “child1” is not ready to be integrated, it will be replaced with a stub.
(ii) Bottom Up Approach
In this approach, modules are testing in the descending manner. For example the module “child1” is tested with module “Parent”. If the module “Parent” is not ready to be integrated, it will be replaced with a driver.
(iii) Big Bang Approach
In this approach, modules are tested all at once.
(iv) Hybrid Integration Approach
In this approach, modules are tested with a mixture of Top-Down and Bottom-Up approaches.
(3) Functional Testing
Functional testing is performed to validate the system is performing according to the requirements and all input permutations with boundary values inputs are used to thoroughly test the software.
Few types of functional testing are as follows.
— Unit Testing
— Smoke Testing
— Sanity Testing
— Integration Testing
— User Acceptance testing
(4) Non Functional Testing
Non functional testing is performed to verify and validate the non functional aspect of the system such as user experience, zero-to-minimal lag, ease of usability, scalability etc. .
Few types of non functional testing are as follows.
— Performance Testing
— Endurance Testing
— Stress Testing
— Security Testing
— Installation Testing
— Penetration Testing
— Compatibility Testing
— Migration Testing
(5) Regression Testing
Regression testing or maintenance testing is focused upon validating the correctness of existing functionality. This is done periodically or when there is change in code or new features are embedded into the system, to verify the functionality of existing modules are not affected, be the modules have direct or indirect relation or have no relation to the change at all.
Further Notes:
This will be completed set of articles for getting started with TestNG. The article list below will be updated periodically. Click on the link to get started!
0 — Understanding Software Testing And Types.
i — Kick Start With TestNG — Chapter 1- Automation Testing Overview.
ii — Kick Start With TestNG — Chapter 2- Setting Up TestNG First Project In Eclipse IDE.
iii — Kick Start With TestNG — Chapter 3- Error Handling with Annotation and Asserts.