Unit Testing and Its Techniques

 What is Unit Or Component Testing :

  • Unit testing is a software development process in which  individual units of source code , sets of one or more computer program modules are tested to determine whether they are fit for use or not. 
  • Testing is conduct by developer or white box tester.
  • To conduct this testing programming knowledge is required. 
  • This technique allows developers to analyze code, catch bugs earlier, and fix them faster.
Levels of Software Testing:

Advantages of Unit Testing 

  • Unit testing significantly improves code quality. 
  • Unit testing helps identify all kinds of issues with the software at a very early stage.
  • If there are any problems, they are detected early on and making changes to the system thus becomes much easier.
  • Reduce Costs

Unit Testing Techniques

  • Structural Testing Techniques
  • Functional Testing 
  • Error Based Testing Techniques 

1. Structural Testing Techniques

Structure-based testing techniques use the internal structure of a software to derive test cases. It is a white box testing technique it required programming skills

Structure-based techniques can also be used at all levels of testing

  •  Statement Testing :- Testing each line in programming at least one time.
  •  Condition Testing:- Verify the conditional statement are working correct or not.
  •  Branch Testing:- Verify all the branch statement are working correct.
  •  Path Testing:- Testing the flow of the execution of the program. 

2. Functional Testing 

  • FUNCTIONAL TESTING is a type of software testing whereby the system is tested against the functional requirements
  •  Functions (or features) are tested by feeding them input and examining the output.
  •  Functional testing ensures that the requirements are properly satisfied by the application.
  •  Functional testing is a quality assurance process and a type of black-box testing.

3. Error Guessing Testing Techniques 

  • Error Guessing is a Software Testing technique on guessing the error which can prevail in the code.
  • It is a black box testing.
  • Error guessing is a technique in which there is no specific method for identifying the error. It is based on the experience of the test analyst
  • Testing is conducted to analyses the impact of the defect on the application.

Please refer below video for more detail on Unit testing:

No comments:

Post a Comment