Integration Test

Integration Test

What

Integration testing is a level of software testing where individual units are combined and tested as a group. It aims to expose faults in the interaction between integrated units.

Why

Integration testing is important as it helps identify issues with the interfaces between components, the interaction between different parts of the system, and so on. It ensures that the integrated components of the system work together as expected.

How

Integration testing can be performed using various tools like Testing Library.
 
 
notion image

Testing Library


 
What
Testing Library is a very light-weight solution for testing without relying on the implementation details of the components. It provides tools for testing the user interface and the way the user would interact with it.
 
Why
The main reason to use Testing Library is its philosophy of testing the component as the user would. This leads to less brittle tests that give more confidence, as they only break when the actual user experience breaks.
 
How
Testing Library provides various queries to find elements on the page and interact with them. It can be combined with a testing framework like Jest to run the tests.
 
Alternatives