• Home
  • Testing
  • SAP
  • Web
  • Must Learn!
  • Big Data
  • Live Projects
  • AI
  • Blog

Unit Tests are conducted by developers and test the unit of code( aka module, component) he or she developed. It is a testing method by which individual units of source code are tested to determine if they are ready to use. It helps to reduce the cost of bug fixes since the bugs are identified during the early phases of development life cycle.

Integration testing is executed by testers and tests integration between software modules. It is a software testing technique where individual units of a program are combined and tested as a group. Test stubs and test drivers are used to assist in Integration Testing. Integration test is performed in two way, they are bottom-up method and the top-down method.

Below is a detailed comparison between the two-

Unit test
Integration test
  • The idea behind Unit Testing is to test each part of the program and show that the individual parts are correct.
  • The idea behind Integration Testing is to combine modules in the application and test as a group to see that they are working fine
  • It can be performed at any time
  • Unit Testing tests only the functionality of the units themselves and may not catch integration errors, or other system-wide issues
  • Integrating testing may detect errors when modules are integrated to build the overall system
  • It starts from the module specification
  • It starts from the interface specification
  • It pays attention to the behavior of single modules
  • It pays attention to integration among modules
  • Unit test does not verify whether your code works with external dependencies correctly.
  • Integration tests verifies that your code works with external dependencies correctly.
  • It is usually executed by developer
  • It is usually executed by test team
  • Finding errors are easy
  • Finding errors are difficult
  • Maintenance of unit test is cheap
  • Maintenance of integration test is expensive