Open In App

Difference between Top Down and Bottom Up Integration Testing

Last Updated : 19 May, 2023
Improve
Improve
Like Article
Like
Save
Share
Report

Prerequisite – Integration Testing 

1. Top Down Integration Testing : Top Down Integration testing which is also known as Incremental integration testing. In this Top Down approach the higher level modules are tested first after higher level modules the lower level modules are tested. Then these modules undergo for integration accordingly. Here the higher level modules refers to main module and lower level modules refers to submodules. This approach uses Stubs which are mainly used to simulate the submodule, if the invoked submodule is not developed this Stub works as a momentary replacement. 
 

Features of Top Down Integration Testing :

  • System-centric approach: Testing focuses on the system as a whole, starting from top-level components.
  • Early testing of higher-level functionality: Testing higher-level functionality is prioritized to identify major issues early.
  • High-level test cases used: Test cases are designed to cover the functionality and interactions of higher-level modules.
  • Mock objects/stubs used: Placeholder objects or stubs simulate lower-level components during testing.
  • Testing becomes progressively detailed: More specific tests are performed as lower-level components are integrated.
  • Efficient approach: Testing higher-level functionality first allows for a quick evaluation of system behavior.
  • Risk-based testing: Critical and risky areas of the system are tested early to mitigate potential risks.
     

2. Bottom Up Integration Testing : Bottom Up Integration testing is another approach of Integration testing. In this Bottom Up approach the lower level modules are tested first after lower level modules the higher level modules are tested. Then these modules undergo for integration accordingly. Here the lower level modules refers to submodules and higher level modules refers to main modules. This approach uses test drivers which are mainly used to initiate and pass the required data to the sub modules means from higher level module to lower level module if required. The below figure represents the Top Down and Bottom up Integration testing approach. 

Features of Bottom Up Integration Testing :

  • Component-Centric: Bottom-up integration testing focuses on testing individual components first before integrating them into larger subsystems.
  • Early Detection: This approach enables early detection of defects in individual components, which can be corrected before integration.
  • Independent Testing: Each component is tested independently, ensuring that it functions correctly in isolation.
  • Incremental Testing: Testing proceeds incrementally from lower-level to higher-level components.
  • Parallel Development: This approach enables parallel development of components by different teams.
  • Efficient Testing: Bottom-up integration testing can be an efficient approach.
  • Risk-Based Testing: Risk-based testing can be applied in bottom-up integration testing to prioritize the testing of high-risk components.
     

 
Difference between Top Down Integration Testing and Bottom Up Integration Testing :

S.No. TOP DOWN INTEGRATION TESTING BOTTOM UP INTEGRATION TESTING
01. Top Down Integration testing is one of the approach of Integration testing in which integration testing takes place from top to bottom means system integration begins with top level modules. Bottom Up Integration testing is one of the approach of Integration testing in which integration testing takes place from bottom to top means system integration begins with lowest level modules.
02. In this testing the higher level modules are tested first then the lower level modules are tested and then the modules are integrated accordingly. In this testing the lower level modules are tested first then the higher level modules are tested and then the modules are integrated accordingly.
03. In this testing stubs are used for simulate the submodule if the invoked submodule is not developed means Stub works as a momentary replacement. In this testing drivers are used for simulate the main module if the main module is not developed means Driver works as a momentary replacement.
04. Top Down Integration testing approach is beneficial if the significant defect occurs toward the top of the program. Bottom Up Integration testing approach is beneficial if the crucial flaws encounters towards the bottom of the program.
05. In Top Down Integration testing approach the main module is designed at first then the submodules/subroutines are called from it. In Bottom Up Integration testing approach different modules are created first then these modules are integrated with the main function.
06. It is implemented on Structure/procedure-oriented programming languages. It is implemented on Object-oriented programming languages.
07. The complexity of this testing is simple. The complexity of this testing is complex and highly data intensive.
08. It works on big to small components. It works on small to big components.
09. In this approach Stub modules must be produced. In this approach, Driver modules must be produced.
10. In terms of cost, Top Down testing is more expensive because it requires the complete system for testing. Bottom Up testing is less expensive as compared to Top Down because it allows early identification and resolution of the model issues. 

Like Article
Suggest improvement
Previous
Next
Share your thoughts in the comments

Similar Reads