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

Wollo College of Informatics: University

The document discusses various topics related to software testing including definitions, types of testing, levels of testing, and manual vs automated testing. It defines software testing as evaluating product quality to identify defects. It distinguishes between verification, which ensures development follows design specifications, and validation, which ensures the product meets user requirements. Testing can be done at the unit, integration, system and acceptance levels using black-box or white-box approaches and either manually or with automated tools.

Uploaded by

Minte Dejene
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views

Wollo College of Informatics: University

The document discusses various topics related to software testing including definitions, types of testing, levels of testing, and manual vs automated testing. It defines software testing as evaluating product quality to identify defects. It distinguishes between verification, which ensures development follows design specifications, and validation, which ensures the product meets user requirements. Testing can be done at the unit, integration, system and acceptance levels using black-box or white-box approaches and either manually or with automated tools.

Uploaded by

Minte Dejene
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 38

Wollo University

College of Informatics
Fundamentals of Software Engineering
Course Code: CoSc3061

07/02/2022 1
Chapter 7
Software Testing

07/02/2022 2
Definitions
Software testing is an activity performed for evaluating

product quality, and for improving it, by identifying


defects and problems.
The process of analyzing a software item to detect the

differences between existing and required conditions ( i.e.,


bugs) and to evaluate the features of the software item”
(IEEE-1993)
“The process of analyzing a program with the intent of

finding errors” (Myers 1979)


07/02/2022 3
Software Testing
Testing is the process of exercising a program with the specific
objective of finding errors prior to delivery to the end user.

Don’t view testing as a “safety net” that will catch all errors that
occurred because of weak software engineering practice.

07/02/2022 4
Who Test the Software?
Developer

Tester
Understands the system but, Must learn about the system,
will test gently but, will attempt to break it
and, is driven by delivery and, is driven by quality

Testing need a strategy.


Testing without plan is no point.
Dev’t team needs to work with Test
 It wastes time and effort
team, “Egoless Programming”
2
07/02/2022 3 5
Software Verification
Vs
Software Validation

07/02/2022 6
Verification Vs Validation…

Verification (Process Oriented)


It is the process of determining whether the output

of one phase of software development conforms to


that of its previous phase
Refers to the set of activities that ensure that

software correctly implements a specific function


It is a static testing strategies.

Involves code walk-through, Inspections and reviews

07/02/2022 7
Software Verification ….cont
Verification is the process of confirming if the software is

meeting the business requirements, and is developed adhering to


the proper specifications and methodologies.
Verification ensures the product being developed is according to

design specifications.
Verification answers the question– "Are we developing this

product by firmly following all design specifications ?"


Verifications concentrates on the design and system
specifications.
07/02/2022 8
Validation
Validation (Product oriented)
It is the process of determining whether the fully developed

system conform to its requirement specifications.


Refers to a different set of activities that ensure that the
software that has been build is traceable to customer
requirement
Aim is to ensure that the final product is error free.

Require Black Box testing techniques

07/02/2022 9
Software Validation ..cont
 Validation is process of examining whether or not the software

satisfies the user requirements.


 It is carried out at the end of the SDLC.

 If the software matches requirements for which it was made, it is

validated.
 Validation ensures the product under development is as per the user

requirements.
 Validation answers the question – "Are we developing the product

which attempts all that user needs from this software ?".
 Validation emphasizes on user requirements.

07/02/2022 10
Target of software testing
are -
Errors - These are actual coding mistakes made by developers.
In addition, there is a difference in output of software and

desired output, is considered as an error.


Fault - When error exists fault occurs.
A fault, also known as a bug, is a result of an error which can

cause system to fail.


Failure - failure is said to be the inability of the system to

perform the desired task.


 Failure occurs when fault exists in the system.
07/02/2022 11
Error, Faults, and Failures..
Cont’d
IEEE Definitions

Failure: External behavior is incorrect.


Fault: inconsistency in code that causes a failure.
Error: Human mistake that caused fault.

07/02/2022 12
Testing Life Cycle and V-model
Similar to the Waterfall Model

The new perspective that the V- Model brings in is

that different types of testing apply at different level.


Splits into two parts- design and execution

Design done early where as execution done only at the

end of the life cycle.

07/02/2022 13
Testing Life Cycle and V-model…

07/02/2022 14
Manual Vs Automated Testing
 Testing can either be done manually or using an automated testing tool:
Manual - This testing is performed without taking help of
automated testing tools.
The software tester prepares test cases for different sections and
levels of the code, executes the tests and reports the result to the
manager.
 It is time and resource consuming. The tester needs to confirm whether or
not right test cases are used. Major portion of testing involves manual
testing.
Automated -This testing is a testing procedure done with aid of
automated testing tools.
The limitations with manual testing can be overcome using
automated test tools.
15
07/02/2022
Testing Approaches
Tests can be conducted based on two approaches –

1.Functionality testing

2.Implementation testing
When functionality is being tested without taking the

actual implementation in concern it is known as black-box


testing.
The other side is known as white-box testing where not

only functionality is tested but the way it is implemented


is also analysed.
07/02/2022 16
Black-box testing
It is carried out to test functionality of the program and also
called ‘Behavioural’ testing.
 The tester in this case, has a set of input values and respective

desired results.
 On providing input, if the output matches with the desired results,

the program is tested ‘ok’, and problematic otherwise.


 In this testing method, the design and structure of the code are not

known to the tester, and testing engineers and end users conduct
this test on the software.

07/02/2022 17
White-box testing

It is conducted to test program and its


implementation, in order to improve code efficiency or
structure.
It is also known as ‘Structural’ testing.

In this testing method, the design and structure of

the code are known to the tester.


Programmers of the code conduct this test on the

code.

07/02/2022 18
Why Both BB and WB Testing?
Black-box testing White-box testing
Impossible to write a Does not address the
test case for every question of whether or not
a program matches the
possible set of inputs
specification
and outputs Does not tell you if all of
Some code parts may the functionality has been
not be accessible or implemented
available. Does not discover missing
Does not tell if extra program logic
functionality has been
implemented.
07/02/2022 19
Testing Levels
Testing itself may be defined at various levels of SDLC.

The testing process runs parallel to software development.

 Before jumping on the next stage, a stage is tested, validated

and verified.
Testing separately is done just to make sure that there are no

hidden bugs or issues left in the software.


Software is tested on various levels -

07/02/2022 20
Testing Levels ….Cont.

Unit Testing
While coding, the programmer performs some tests on that

unit of program to know if it is error free.


 Unit testing is testing of individual software components or modules.

Typically done by the programmer not by tester, as it requires

detailed knowledge of the internal program design and code.


 Unit testing helps developers decide that individual units of

the program are working as per requirement and are error free.

07/02/2022 21
Testing Levels ….Cont.
System Testing
 The software is compiled as product and then it is tested as whole.
 This can be accomplished using one or more of the following tests:
 Functionality testing - Tests all functionalities of the software
against the requirement.
 Performance testing - This test proves how efficient the
software is.
 It tests the effectiveness and average time taken by the
software to do desired task.
 Performance testing is done by means of load testing and stress
testing where the software is put under high user and data load
under various environment conditions.
 Security & Portability - These tests are done when the
software is meant to work on various platforms and accessed by
number of persons.
07/02/2022 22
Testing Levels ….Cont.

Regression Testing
Whenever a software product is updated with new

code, feature or functionality, it is tested thoroughly to


detect if there is any negative impact of the added
code. This is known as regression testing.
Difficult to test all the system in regression testing so

typically automation tools are used for these types of


testing.
07/02/2022 23
Testing Levels
Integration Testing
Testing of integrated modules to verify
combined functionality after integrated.
Modules are typically code module ,individual

applications, client and server applications on a


network etc.
This types of testing is especially relevant to

client/server and distributed system


07/02/2022 24
Integration Testing…..
 The primary objective of integration testing is to test the

module interface in order to ensure that there are no errors in


the parameter passing, when one module invokes another module.
 In integration testing, different modules making of the system

are integrated in a planned manner using an integration plan.


 Two Strategies:

 Phased integration testing

 Incremental integration testing

07/02/2022 25
Integration Testing…

Phased integration
 A group of related modules are added, each time, to the partial system

under test.

Incremental integration
 Only one new module is added, each time, to the partial system under test.

Different approaches for integration testing:


Big-bang approach

Top-down approach

Bottom–up approach

Mixed approach

07/02/2022 26
Big-Bang Integration
Testing
It is the simplest integration testing approach, where all the modules
making up a system are integrated in a single step.
 In simple words, all the modules of the system are simply put together
and tested.
However, this technique is feasible only for very small systems.
 The main problem with this approach is that once an error is found
during the integration testing, it is very difficult to limit the error as
the error may potentially belong to any of the modules being
integrated.
 Therefore, debugging errors reported during big bang integration
testing are very expensive to fix.
07/02/2022 27
Integration Testing…

07/02/2022 28
Top-Down Integration
Testing
It starts with the main routine and one or two subordinate
routines in the system.
After the top-level ‘skeleton’ has been tested, the immediately
subroutines of the ‘skeleton’ are combined with it and tested.
Top-down integration testing approach requires the use of
program stubs to simulate the effect of lower-level routines
that are called by the routines under test.
A pure top-down integration does not require any driver routines.

07/02/2022 29
Integration Testing…

Top Down Integration

07/02/2022 30
Bottom-Up Integration
 In bottom-up testing, each subsystem is tested separately and
then the full system is tested.
A subsystem might consist of many modules which communicate
among each other through well-defined interfaces.
The primary purpose of testing each subsystem is to test the
interfaces among various modules making up the subsystem.
 Both control and data interfaces are tested.
The test cases must be carefully chosen to exercise the
interfaces in all possible manners.

07/02/2022 31
Integration Testing…
Bottom-Up Integration

07/02/2022 32
Mixed Integration
A mixed integration testing follows a combination of top down and
bottom-up testing approaches.
In top-down approach, testing can start only after the top-level
modules have been coded and unit tested.
Similarly, bottom-up testing can start only after the bottom level
modules are ready.
The mixed approach overcomes this shortcoming of the top-down and
bottom-up approaches.
In the mixed testing approaches, testing can start as and when
modules become available.
Therefore, this is one of the most commonly used integration testing
approaches.
07/02/2022 33
Integration Testing…
Sandwich Testing

07/02/2022 34
Testing Levels ….Cont.

Acceptance Testing
 When the software is ready to hand over to the customer it has to go

through last phase of testing where it is tested for user-interaction


and response.
 This is important because even if the software matches all user

requirements and if user does not like the way it appears or works, it
may be rejected.
 Alpha testing - The team of developer themselves perform alpha
testing by using the system as if it is being used in work environment.
 They try to find out how user would react to some action in
software and how the system should respond to inputs.

07/02/2022 35
Testing Levels ….Cont.

Acceptance Testing

 Beta testing - After the software is tested


internally, it is handed over to the users to use it
under their production environment only for testing
purpose.
 This is not as yet the delivered product.
 Developers expect that users at this stage will bring
minute problems, which were skipped to attend.

07/02/2022 36
Difference between testing and debugging
Testing is the process of finding bugs or errors in a

software product that is done manually by the tester or an


be automated.
 It is the process to check if the system is working same as

supposed to do, and not working as it was not supposed to do.

Debugging is a process of fixing bugs found in testing phase.


 Programmer or developer is responsible for debugging and it

can’t be automated.

07/02/2022 37
Difference between testing and debugging
Testing Debugging
 The purpose of debugging is
 The purpose of testing is to to correct those bugs found
find bugs and errors during testing.
 Testing is done by tester.  Debugging is done by
 It can be automated. programmer or developer.
 It can’t be automated.
 It can be done by outsider like
 It can be done only by
clients
insider i.e. programmer.
 Most of testing can be done
 Debugging can’t be done
Without design knowledge. without proper design
knowledge.

07/02/2022 38

You might also like