Integration Testing

[vc_row css=”.vc_custom_1563551056652{margin-top: -100px !important;}”][vc_column][vc_column_text]

Integration Testing

[/vc_column_text][/vc_column][/vc_row][vc_row full_width=”stretch_row_content_no_spaces”][vc_column width=”1/6″][/vc_column][vc_column width=”2/3″ css=”.vc_custom_1563561629737{padding-right: 30px !important;padding-left: 30px !important;background-color: #efede8 !important;}”][vc_column_text]Integration testing is done to test the modules/components when integrated to verify that they work as expected i.e. to test the modules which are working fine individually does not have issues when integrated.

When talking in terms of testing large application using black box testing technique, involves the combination of many modules which are tightly coupled with each other. We can apply the Integration testing technique concepts for testing these types of scenarios.[/vc_column_text][/vc_column][vc_column width=”1/6″][/vc_column][/vc_row][vc_row full_width=”stretch_row_content_no_spaces”][vc_column width=”1/6″][/vc_column][vc_column width=”2/3″ css=”.vc_custom_1563550917050{padding-right: -30px !important;padding-left: -30px !important;background-color: #efede8 !important;}”][vc_tta_accordion style=”modern” color=”turquoise” active_section=”1″][vc_tta_section title=”What Is Integration Testing?” tab_id=”1563561494989-8ebf41b0-89c1″][vc_column_text]The meaning of Integration testing is quite straightforward- Integrate/combine the unit tested module one by one and test the behavior as a combined unit.

The main function or goal of this testing is to test the interfaces between the units/modules.

We normally do Integration testing after “Unit testing”. Once all the individual units are created and tested, we start combining those “Unit Tested” modules and start doing the integrated testing.

The main function or goal of this testing is to test the interfaces between the units/modules.

The individual modules are first tested in isolation. Once the modules are unit tested, they are integrated one by one, till all the modules are integrated, to check the combinational behavior, and validate whether the requirements are implemented correctly or not.

Here we should understand that Integration testing does not happen at the end of the cycle, rather it is conducted simultaneously with the development. So in most of the times, all the modules are not actually available to test and here is what the challenge comes to test something which does not exist![/vc_column_text][/vc_tta_section][vc_tta_section title=”Why Integration Test?” tab_id=”1563561495068-d674954b-9ed4″][vc_column_text]We feel that Integration testing is complex and requires some development and logical skill. That’s true! Then what is the purpose of integrating this testing into our testing strategy?

Here are some reasons:

  1. In the real world, when applications are developed, it is broken down into smaller modules and individual developers are assigned 1 module. The logic implemented by one developer is quite different than another developer, so it becomes important to check whether the logic implemented by a developer is as per the expectations and rendering the correct value in accordance with the prescribed standards.
  2. Many a time the face or the structure of data changes when it travels from one module to another. Some values are appended or removed, which causes issues in the later modules.
  3. Modules also interact with some third party tools or APIs which also need to be tested that the data accepted by that API / tool is correct and that the response generated is also as expected.
  4. A very common problem in testing – Frequent requirement change! 🙂 Many a time developer deploys the changes without unit testing it. Integration testing becomes important at that time.


There are several advantages of this testing and few of them are listed below.

  • This testing makes sure that the integrated modules/components work properly.
  • Integration testing can be started once the modules to be tested are available. It does not require the other module to be completed for testing to be done, as Stubs and Drivers can be used for the same.
  • It detects the errors related to the interface.

[/vc_column_text][/vc_tta_section][vc_tta_section title=”Challenges” tab_id=”1563561495147-e79a7016-6d24″][vc_column_text]Listed below are few challenges that are involved in Integration Test.

#1) Integration testing means testing two or more integrated systems in order to ensure that the system works properly. Not only the integration links should be tested but an exhaustive testing considering the environment should be done to ensure that the integrated system works properly.

There might be different paths and permutations which can be applied to test the integrated system.

#2) Managing Integration testing becomes complex because of few factors involved in it like the database, Platform, environment etc.

#3) While integrating any new system with the legacy system, it requires a lot of changes and testing efforts. Same applies while integrating any two legacy systems.

#4) Integrating two different systems developed by two different companies is a big challenge as for how one of the systems will impact the other system if any changes are done in any one of the systems is not sure.

In order to minimize the impact while developing a system, few things should be taken into consideration like possible integration with other systems, etc.[/vc_column_text][/vc_tta_section][vc_tta_section title=”Types Of Integration Testing” tab_id=”1563561495245-093f9a7e-4c8f”][vc_column_text]Given below is a type of Test Integration along with its advantages and disadvantages.

Big Bang Approach:

Big bang approach integrates all the modules in one go i.e. it does not go for integrating the modules one by one. It verifies if the system works as expected or not once integrated. If any issue is detected in the completely integrated module, then it becomes difficult to find out which module has caused the issue.

Big bang approach is a time-consuming process of finding a module which has a defect itself as that would take time and once the defect is detected, fixing the same would cost high as the defect is detected at the later stage.[/vc_column_text][/vc_tta_section][vc_tta_section title=”Test Integration Approaches” tab_id=”1563561495326-7443c256-27b0″][vc_column_text]

Bottom-up approach:

Bottom-up testing, as the name suggests starts from the lowest or the innermost unit of the application, and gradually moves up. The Integration testing starts from the lowest module and gradually progresses towards the upper modules of the application. This integration continues till all the modules are integrated and the entire application is tested as a single unit.

In this case, modules B1C1, B1C2 & B2C1, B2C2 are the lowest module which is unit tested. Module B1 & B2 are not yet developed. The functionality of Module B1 and B2 is that it calls the modules B1C1, B1C2 & B2C1, B2C2. Since B1 and B2 are not yet developed, we would need some program or a “stimulator” which will call the B1C1, B1C2 & B2C1, B2C2 modules. These stimulator programs are called DRIVERS.

In simple words, DRIVERS are the dummy programs which are used to call the functions of the lowest module in a case when the calling function does not exist. The bottom-up technique requires module driver to feed test case input to the interface of the module being tested.

The advantage of this approach is that, if a major fault exists at the lowest unit of the program, it is easier to detect it, and corrective measures can be taken.

The disadvantage is that the main program actually does not exist until the last module is integrated and tested. As a result, the higher level design flaws will be detected only at the end.

Top-down approach

This technique starts from the topmost module and gradually progress towards the lower modules. Only the top module is unit tested in isolation. After this, the lower modules are integrated one by one. The process is repeated until all the modules are integrated and tested.

[/vc_column_text][/vc_tta_section][vc_tta_section title=”GUI Application Integration Test” tab_id=”1563561495411-2a380ce9-2903″][vc_column_text]Now let’s talk about how we can imply integration testing in Black box technique.

We all understand that a web application is a multitier application. We have a front end which is visible to the user, we have a middle layer which has business logic, we have some more middle layer which does some validations, integrate some third party APIs etc., then we have the back layer which is the database.

Integration testing example:

Let’s check the below example:

I am the owner of an advertising company and I post ads on different websites. At the end of the month, I want to see how many people saw my ads and how many people clicked on my ads. I need a report for my ads displayed and I charge accordingly to my clients.

UI – User Interface module, which is visible to the end user, where all the inputs are given.
BL – Is the Business Logic module, which has all the all the calculations and business specific methods.
VAL – Is the Validation module, which has all the validations of the correctness of the input.
CNT – Is the content module which has all the static contents, specific to the inputs entered by the user. These contents are displayed in the reports.
EN – Is the Engine module, this module reads all the data that comes from BL, VAL and CNT module and extracts the SQL query and triggers it to the database.
Scheduler – Is a module which schedules all the reports based on the user selection (monthly, quarterly, semiannually & annually)
DB – Is the Database.

Now, having seen the architecture of the entire web application, as a single unit, Integration testing, in this case, will focus on the flow of data between the modules.

The questions here are:

  1. How the BL, VAL and the CNT module will read and interpret ate the data entered in the UI module?
  2. Is BL, VAL and CNT module receiving the correct data from UI?
  3. In which format the data from BL, VAL and CNT is transferred to the EQ module?
  4. How will the EQ read the data and extract the query?
  5. Is the query extracted correctly?
  6. Is the Scheduler getting the correct data for reports?
  7. Is the result set received by the EN, from the database is correct and as expected?
  8. Is EN able to send the response back to the BL, VAL and CNT module?
  9. Is UI module able to read the data and display it appropriately to the interface?

In the real world, the communication of data is done in an XML format. So whatever data the user enters in the UI, it gets converted into an XML format.

In our scenario, the data entered in the UI module gets converted into XML file which is interpreted by the 3 modules BL, VAL and CNT. The EN module reads the resultant XML file generated by the 3 modules and extracts the SQL from it and queries into the database. The EN module also receives the result set and converts it into an XML file and returns it back to the UI module which converts the results in user readable form and displays it.

In the middle we have the scheduler module which receives the result set from the EN module, creates and schedules the reports.

So where Integration testing does comes into the picture?

Well, testing whether the information/data is flowing correctly or not will be your integration testing, which in this case would be validating the XML files. Are the XML files generated correctly? Do they have the correct data? Are the data is being transferred correctly from one module to another? All these things will be tested as part of Integration testing.

Try to generate or get the XML files and update the tags and check the behavior. This is something very different from the usual testing which testers normally do, but this will add value to the testers knowledge and understanding of the application.[/vc_column_text][/vc_tta_section][vc_tta_section title=”Steps To Kick Off Integration Tests” tab_id=”1563561495499-f79c4117-3751″][vc_column_text]

  1. Understand the architecture of your application.
  2. Identify the modules
  3. Understand what each module does
  4. Understand how the data is transferred from one module to another.
  5. Understand how the data is entered and received into the system ( entry point and exit point of the application)
  6. Segregate the application to suit your testing needs.
  7. Identify and create the test conditions
  8. Take one condition at a time and write down the test cases.

[/vc_column_text][/vc_tta_section][vc_tta_section title=”Entry/Exit Criteria For Integration Testing” tab_id=”1563561495602-61b738ca-c6cb”][vc_column_text]Entry Criteria:

  • Integration test plan document is signed off and approved.
  • Integration test cases have been prepared.
  • Test data has been created.
  • Unit testing of developed modules/Components is complete.
  • All the critical and high Priority defects are closed.
  • The test environment is set up for integration.

Exit Criteria:

  • All the integration test cases have been executed.
  • No critical and Priority P1 & P2 defects are opened.
  • Test Report has been prepared.

[/vc_column_text][/vc_tta_section][vc_tta_section title=”Integration Test Cases” tab_id=”1563561495702-3299e16b-4f10″][vc_column_text]Integration test cases focus mainly on the interface between the modules, integrated links, data transfer between the modules as modules/components that are already unit tested i.e. the functionality and the other testing aspects have already been covered.

So, the main idea is to test if integrating two working modules works as expected when integrated.

For Example Integration Test cases for Linkedin application will include:

  • Verifying the interface link between the login page and the home page i.e. when a user enters the credentials and logs it should be directed to the homepage.
  • Verifying the interface link between the home page and the profile page i.e. profile page should open up.
  • Verify the interface link between the network page and your connection pages i.e. clicking accept button on Invitations of the network page should show the accepted invitation in your connection page once clicked.
  • Verify the interface link between the Notification pages and say congrats button i.e. clicking say congrats button should direct towards the new message window.

Many integration test cases can be written for this specific site. The above four points are just an example to understand what Integration test cases are included in testing.[/vc_column_text][/vc_tta_section][vc_tta_section title=”Integration Testing Tools” tab_id=”1563561495810-d3e9ac14-deca”][vc_column_text]There are several tools available for this testing.

Given below is a list of tools:

  • Rational Integration Tester
  • Protractor
  • Steam

[/vc_column_text][/vc_tta_section][vc_tta_section title=”Integration Testing Tools” tab_id=”1563561495913-b1c5ad75-a285″][vc_column_text]There are several tools available for this testing.

Given below is a list of tools:

  • Rational Integration Tester
  • Protractor
  • Steam

[/vc_column_text][/vc_tta_section][vc_tta_section title=”System Integration Testing” tab_id=”1563561496029-903e773f-4de2″][vc_column_text]System Integration Test is done to test the complete integrated system.

Modules or components are tested individually in unit testing before integrating the components.

Once all the modules are tested, system integration testing is done by integrating all the modules and the system as a whole is tested.[/vc_column_text][/vc_tta_section][/vc_tta_accordion][/vc_column][vc_column width=”1/6″][/vc_column][/vc_row]

WhatsApp us