0% found this document useful (0 votes)
200 views

UNIT 8 - Software - Testing - Strategies

Software testing strategies include black box and white box testing. Black box testing focuses on external behavior without knowledge of internal workings. It includes techniques like equivalence partitioning and boundary value analysis. White box testing checks internal code and paths. It focuses on achieving high statement, branch, and condition coverage through techniques like condition coverage and basis path testing. Conventional software is tested through unit, integration, regression, and smoke testing strategies.

Uploaded by

vikas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
200 views

UNIT 8 - Software - Testing - Strategies

Software testing strategies include black box and white box testing. Black box testing focuses on external behavior without knowledge of internal workings. It includes techniques like equivalence partitioning and boundary value analysis. White box testing checks internal code and paths. It focuses on achieving high statement, branch, and condition coverage through techniques like condition coverage and basis path testing. Conventional software is tested through unit, integration, regression, and smoke testing strategies.

Uploaded by

vikas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 32

Software Testing Strategies

UNIT VIII
Introduction

 Testing is a process of executing a program


with the aim of finding error.

 To make our software perform well it


should be error free.

 If testing is done successfully it will remove


all the errors from the software.
Principles of Testing

1. All tests should meet the customer requirements.

2. To make our software testing should be performed by third

party.

3. All the test to be conducted should be planned before

implementing it.

4. Start testing with small parts and extend it to large parts.


Classification

Software Testing can be majorly classified into two


categories:

 Black Box Testing

 White Box Testing


Black Box

 In Black-box testing, a tester doesn't have any information about


the internal working of the software system.

 Black box testing is a high level of testing that focuses on the


behavior of the software.

 It involves testing from an external or end-user perspective.

 Black box testing can be applied to virtually every level of


software testing: unit, integration, system, and acceptance.
Black Box

Black box testing can be done in following ways:

1. Syntax Driven Testing :

This type of testing is applied to systems that


can be syntactically represented by some
language.

For example- compilers , language that can be represented


by context free grammar.
Black Box

2. Equivalence partitioning :
-> It is often seen that many type of inputs work
similarly so instead of giving all of them separately
we can group them together and test only one input
of each group.
-> The idea is to partition the input domain of the
system into a number of equivalence classes such
that each member of class works in a similar way,
i.e., if a test case in one class results in some error,
other members of class would also result into same
error.
Black Box

3. Boundary value analysis


-> Boundaries are very good places for errors to occur.
Hence if test cases are designed for boundary values
of input domain then the efficiency of testing
improves and probability of finding errors also
increase.

-> For example – If valid range is 10 to 100 then test


for 10,100 also apart from valid and invalid inputs.
Black Box

4. Cause effect Graphing

-> This technique establishes relationship between


logical input called causes with corresponding
actions called effect.

-> The causes and effects are represented using


Boolean graphs.
Black Box

The following steps are followed in cause effect


graphing :

 Identify inputs (causes) and outputs (effect).

 Develop cause effect graph.

 Transform the graph into decision table.

 Convert decision table rules to test cases.


Black Box

5. Requirement based testing – It includes


validating the requirements given in SRS of software
system.
6. Compatibility testing – The test case result not
only depend on product but also infrastructure for
delivering functionality. When the infrastructure
parameters are changed it is still expected to work
properly.
White Box

 White-box testing is a testing technique which checks the


internal functioning of the system.

 In this method, testing is based on coverage of code statements,


branches, paths or conditions. White-Box testing is considered as
low-level testing.

 It is also called glass box, transparent box, clear box or code base
testing.

 The white-box Testing method assumes that the path of the logic
in a unit or program is known.
Working Process of White Box

 Input: Requirements, Functional specifications, design


documents, source code.
 Processing: Performing risk analysis for guiding
through the entire process.
 Proper test planning: Designing test cases so as to
cover entire code. Execute rinse-repeat until error-free
software is reached. Also, the results are communicated.
 Output: Preparing final report of the entire testing
process.
Testing techniques of White Box

 Statement coverage:
->In this technique, the aim is to traverse all statement
at least once. Hence, each line of code is tested.
-> In case of a flowchart, every node must be traversed
at least once. Since all lines of code are covered,
helps in pointing out faulty code.
Testing techniques of White Box

Branch Coverage :

-> In this technique, test cases are designed so that


each branch from all decision points are traversed at
least once.

-> In a flowchart, all edges must be traversed at least


once.
Testing techniques of White Box

 Condition Coverage: In this technique, all


individual conditions must be covered

 Multiple Condition Coverage: In this technique,


all the possible combinations of the possible
outcomes of conditions are tested at least once
Testing techniques of White Box

 Basis Path Testing:


In this technique, control flow graphs are
made from code or flowchart and then
Cyclomatic complexity is calculated
which defines the number of
independent paths so that the minimal
number of test cases can be designed
for each independent path.
Testing techniques of White Box

 Loop Testing:
->Loops are widely used and these are fundamental to
many algorithms hence, their testing is very
important.
-> Errors often occur at the beginnings and ends of
loops.
-> Different strategies are used for different types of
loops like simple ,Nested loops.
Conventional Software

 Conventional software is
the software or applications which
perform some particular task.
 For example : desktop application,
Microsoft Power point, Ms Excel etc are
considered as conventional
software.
Strategies for conventional software

1. Unit testing

2. Integration testing

3. Regression testing

4. Smoke testing
 Unit testing focus on the smallest unit of software
design, i.e module or software component.
 Test strategy conducted on each module interface to
access the flow of input and output.
 The local data structure is accessible to verify
integrity during execution.
 Boundary conditions are tested.
 In which all error handling paths are tested.
Integration testing

 Integration testing is used for the construction of


software architecture.

There are two approaches of incremental


testing are:
i) Non incremental integration testing
ii) Incremental integration testing
Non incremental integration testing

 Combines all the components in advanced.

 A set of error is occurred then the correction is


difficult because isolation cause is complex.
Incremental integration testing

 The programs are built and tested in small increments.

 The errors are easier to correct and isolate.

 Interfaces are fully tested and applied for a systematic


test approach to it.
Incremental integration strategies

a. Top-down integration

b. Bottom-up integration
Top-down integration

 It is an incremental approach for building the


software architecture.
 It starts with the main control module or program.
 Modules are merged by moving downward through
the control hierarchy.
Bottom-up integration

In bottom up integration testing the


components are combined from the
lowest level in the program
structure.
implemented in following steps

 The low level components are merged into clusters


which perform a specific software sub function.
 A control program for testing(driver) coordinate test
case input and output.
 After these steps are tested in cluster.
 The driver is removed and clusters are merged by
moving upward on the program structure.
Regression & Smoke testing

 Regression Testing :
In regression testing the software architecture changes
every time when a new module is added as part of
integration testing.
 Smoke Testing :
The developed software component are translated into
code and merge to complete the product.

You might also like