b) Definition, Goal and its use
● When to use? and Why?
● Types of techniques
● Advantages and Disadvantages
● White-box/Structure-based measures and its related
design techniques are described in BS7925-2
● A software testing technique whereby explicit
knowledge of the internal workings of the item
being tested are used to select the test data.
● White Box testing is based on specific knowledge
of the source code to define the test cases and to
● Testing based on an analysis of the internal
structure of the component or system.
● White Box testing is also known as Clear Box
testing, Glass Box testing, Transparent Box testing,
and Structure-Based testing.
● It can be applied at all levels of SDLC.
● Most of the defects are found in Unit, Component
& Integration levels is through White-box.
The percentage of executable statements that have
been exercised by a test suite.
Coverage = Number of statements exercised
Total number of statements
STATEMENT COVERAGE EXAMPLE
IF a > 6 THEN
B = a
● Here in this example Statement coverage is
B = a
The percentage of decision outcomes that
have been exercised by a test suite.
100% decision coverage implies 100%
Decision coverage =
Number of decision outcomes exercised
Total number of decision outcomes
C = A – 2*B
IF C < 0 THEN
PRINT “C negative”
Read A, B
C < 0
In this white Box testing technique try to cover
100% condition coverage of the code, it means
while testing the every possible conditions in the
code is executed at least once.
MULTIPLE CONDITION COVERAGE:
In this type of testing we use to cover each every
point of the system to be execute once.
In the actual development process developers are
make use of the combination of techniques those
are suitable for there software application.
● It helps in optimizing
● Extra lines of code
can be removed.
● Due to the tester's
knowledge about the
coverage is attained
during test scenario
● Costs expensive
method of testing.
● It is difficult to
maintain white box
testing as the use of
specialized tools like
code analyzers and
debugging tools are
Black Box Testing White Box Testing
1. Internal Workings of an
application are not required.
1. Knowledge of the Internal
workings is must.
2. Also known as closed
box/data driven testing.
2. Also known as clear box
3. End users,testers and
3. Normally done by testers
4. This can only be done by
trial and error method.
4. Data domains and Internal
boundaries can be better