Integration Testing in Software Engineering

Integration Testing

  • Integration testing is a level of software testing in which units/components are integrated in a single module and then test to check communication between these components.
  • Integration Testing is the second level of software testing which is done after unit testing and before system testing. When the integration testing is performed on the modules, system testing is performed.
  • This testing comes under both black box and white box testing. This testing is done by software testers or developers.
  • This testing is also known as ‘I & T’ (Integration and Testing), ‘String Testing’ and ‘Thread Testing’. This testing is an extension of unit testing.
  • The term ‘integrate’ refers to combine two or more things in a single thing to become more effective . The term defines the concept of integration testing. 
  • The main goal of integration testing is to test the functional, performance, and reliability between the components that are integrated.

  • The modules tested individually in unit testing then integrate them one by one until all the modules are integrated and check the flow of data between the modules.

  • The test cases of integration testing differs from other test cases i.e. it only focuses on the interfaces & flow of the data between the modules. 

Integration Testing

Objective of Integration Testing :

  • To reduce risk in system testing
  • Integration Testing is performed to verify the software modules work correctly.
  • If client alters the requirements then integration testing is necessary because new requirements may not be tested. 
  • Sometimes, modules communicate with third party APIs or tools so it is necessary to test that data accepted by that tool/API is correct and generates expected response or not. 
  • If developer deploys the change in requirements and not perform unit testing on them then integration testing is necessary.
  • This testing is necessary to build confidence in the quality of the interfaces.
  • To find issues/bugs if present in the interface or components or systems.

Workflow of Integration Testing :

The workflow of Integration Testing is given below : 

  1. Prepare Test Plan
  2. Develop the test scenarios, test cases, and scripts.
  3. Execute test Cases.
  4. Tracking & re-testing the bugs/defects.
  5. Steps 3 and 4 are repeated until integration testing is completed successfully.

Integration Testing Tools :

  • JUnit
  • VectorCAST/C++
  • TestNG
  • Citrus Integration Testing
  • Mockito
  • Rational Integration Tester
  • FitNesse
  • Jasmine
  • Steam
  • REST Assured

Approaches of Integration Testing :

There are three main approaches/strategies in the integration testing that are mentioned below :

  • Incremental Testing

Top-down approach

Bottom-up approach

  • Non-incremental Testing

         Big-Bang approach

  •  Hybrid Testing

Advantages of Integration Testing :

  • This testing provides faster development and increased confident level.
  • It is easy to combine different modules.
  • Code coverage is high than other approaches.
  • It easily caught system level issues like mistakes in integration,broken database etc.
  • This testing can start when the relevant modules/components are available.It is not necessary to wait until all the modules are implemented and unit tested.

  • Integration testing can be used in the early as well as later stages of the testing process and defects find easily.

  • This testing makes sure that the combined modules works properly.

Disadvantages of Integration Testing :

  • To be precise the success of Integration Testing lies in the perfection of the test plan.
  • Test plan is made by humans one needs to serve for its inefficiencies.
  • If any scenario is not covered in the test plan then errors can be occurs in the system testing.
  • This testing can be time-consuming.