Integration Testing: Ernestas Kardzys, IFME-0/2 WWW - Ernestas.info
Integration Testing: Ernestas Kardzys, IFME-0/2 WWW - Ernestas.info
Integration Testing: Ernestas Kardzys, IFME-0/2 WWW - Ernestas.info
Agenda
What
Is Unit Testing?
What Is Integration Testing?
Terminology
Different Types of Integration Testing:
Questions
make sure
that your
components
satisfy the
fallowing
requirements:
Functional.
Performance.
Reliability.
Terminology (1)
Stub
Terminology (2)
Bottleneck
a
phenomenon where the
performance or capacity of
an entire system is limited
by a single or limited
number of components or
resources.
Regression testing - any
type of software testing that
seeks to uncover new errors,
or regressions, in existing
functionality after changes
have been made to the
software, such as functional
enhancements, patches or
configuration changes.
Disadvantages of Big
Bang
Defects
But
it might be good
with this
assumption applied:
for small systems,
but not for
enterprise level
applications.
11
How To Integrate?
If
12
bottom up
integration testing,
module at the lowest
level are developed first
and other modules
which go towards the
'main' program are
integrated and tested
one at a time.
Bottom up integration
also uses test drivers to
drive and pass
appropriate data to the
lower level modules.
13
15
Comments on Graphical
Representation
Modules
16
17
Disadvantages of Bottom-up
Testing
Writing
18
Top-down Testing
Top
19
do not have
to be written
when top down
testing is used.
It provides early
working module of
the program and
so design defects
can be found and
corrected early.
20
Disadvantages of Top-down
Testing
Stubs
21
probably
use a
combination of
these two
techniques.
Its
called
Sandwich testing
strategy.
22
strategy
The system is view as having three layers
A target layer in the middle
A layer above the target
A layer below the target
Testing converges at the target layer
How do you select the target layer if there
are more than 3 layers?
Heuristic: Try to minimize the number of
stubs and drivers
23
Graphical Representation of
Sandwich Testing Strategy
A
Bottom
Level
Tests
TestE
LevelI
LevelII
H
LevelIII
TestB,E,F
TestF
TestG
TestD,G,H
Test
A,B,C,D,
E,F,G,H
TestH
TestA,B,C,D
Top
Level
Tests
TestA
24
Comments on Graphical
Representation
Modules
and Bottom
Layer Tests can be
done in parallel.
Does not test the
individual
subsystems
thoroughly before
integration.
26
are three
main types of
speed-related
testing:
performance
testing, load
testing and
stress testing.
27
Performance testing
The
goal of
performance
testing is not to
find bugs, but to
eliminate
bottlenecks and
establish a
baseline for
future
regression
testing.
28
Load Testing
Load
testing is
usually defined as
the process of
exercising the system
under test by feeding
it the largest tasks it
can operate with.
Load testing is
sometimes called
volume testing, or
longevity/enduranc
e testing.
29
a word processor by
editing a very large document
Testing a printer by sending it a
very large job
Testing a mail server with
thousands of users mailboxes
A specific case of volume testing
is zero-volume testing, where
the system is fed empty tasks
30
conducted to
evaluate a system or
component at or
beyond the limits of its
specified requirements
to determine the load
under which it fails and
how.
A graceful degradation
under load leading to
non-catastrophic
failure is the desired
result.
31
testing tries to
break the system under
test by overwhelming its
resources or by taking
resources away from it
(in which case it is
sometimes called
negative testing).
The main purpose behind
this madness is to make
sure that the system fails
and recovers gracefully -this quality is known as
recoverability.
32
Apache Benchmarking
(ab)
ab
is a tool for
benchmarking Apache
server. It is designed to give
you an impression of how
Apache installation
performs.
Installation: #apt-get
install apache2-utils
#ab -kc 10 -t 30
http://localhost/
This will open 10
connections, using KeepAlive on them and
hammering localhost for 30
seconds through those
connections.
Boing AH64 Apache
33
Recommendations for
Integration Testing
OK,
34
Steps of Integration
Testing (1)
Select
component to test
and unit test the classes
of the component.
Put selected component
into system. Do any
preliminary fix-up
necessary to make the
integration test
operational (drivers,
stubs).
Define test cases that
exercise all uses cases
with the selected
component
35
Steps of Integration
Testing (2)
Define
primary goal of
integration testing is to
identify errors in the
(current) component
configuration.
36
the units of a
system must be
integrated
consequtively
and integrated
in step by step
process by
incrementing the
levels of testing
at one end to
other end.
37
38
Literature (1)
http://en.wikipedia.org/wiki/Unit_
testing
http://en.wikipedia.org/wiki/Syst
em_integration_testing
http://en.wikipedia.org/wiki/Integ
ration_testing
http://msdn.microsoft.com/en-u
s/library/aa292128%28v=vs.71%2
9.aspx
http://www.testinggeek.com/
http://swen.uwaterloo.ca/~kostas
39
Literature (2)
http://www.debianhelp.co.uk/apa
cheab.htm
http://agiletesting.blogspot.com/
2005/02/performance-vs-load-vs-st
ress-testing.html
http://en.wikipedia.org/wiki/Regre
ssion_testing
http://en.wikipedia.org/wiki/Bottl
eneck
40
Youtube Links
http://www.youtube.com/watch?v=
J22IjXlHI4Y&feature=feedu
[Lecture Software Integration
Testing, 1:50].
http://www.youtube.com/watch?
v=bgIAnWfNLOw&playnext=1&list
=PLF7935AFA888C74E2
[Integration Testing In Software
Testing Projects, 5:46]
http://www.youtube.com/watch?v
=czyoKfWp6z4
41
42
43