You are on page 1of 1

What are unit, component and integration testing?

Note that the definitions of unit, component, integration, and

integration testing are recursive :

Unit: The smallest compliable component. A unit typically is the work of one programmer (At least
in principle). As defined, it does not include any called sub-components (for procedural languages) or
communicating components in general.

Unit testing: in unit testing called components (or communicating components) are replaced with
stubs, simulators, or trusted components. Calling components are replaced with drivers or trusted
super-components. The unit is tested in isolation.

Component: a unit is a component. The integration of one or more components is a component .


Note: The reason for "one or more" as contrasted to "Two or more" is to allow for components that
call themselves recursively.

Component testing: same as unit testing except that all stubs and simulators are replaced with
the real thing.
Two components (actually one or more) are said to be integrated when:
a. They have been compiled, linked, and loaded together.
b. They have successfully passed the integration tests at the interface between them.
Thus, components A and B are integrated to create a new, larger, component (A,B). Note that this
does not conflict with the idea of incremental integrationit just means that A is a big component and
B, the component added, is a small one.
Integration testing: carrying out integration tests.
Integration tests (After Leung and White) for procedural languages. This is easily generalized for OO
languages by using the equivalent constructs for message passing. In the following, the word "call" is
to be understood in the most general sense of a data flow and is not restricted to just formal
subroutine calls and returns for example, passage of data through global data structures and/or the
use of pointers.

You might also like