Beruflich Dokumente
Kultur Dokumente
(Continued)
(Lecture 15)
Prof. R. Mall
Dept. of CSE, IIT, Kharagpur
Review of last lecture. Data flow testing Mutation testing Cause effect graphing Performance testing. Test summary report Summary
to the locations of
is defined at a statement S:
There
DU Chain Example
1 X(){ 2 a=5; /* Defines variable a */ 3 While(C1) { 4 if (C2) 5 b=a*a; /*Uses variable a */ 6 a=a-1; /* Defines variable a */ 7 } 8 print(a); } /*Uses variable a */
6
[X,S,S1],
5
6 7
8
9 B6 }
else B3;
10
Mutation Testing
using an initial testing method based on white-box strategies we already discussed. mutation testing is taken up. make a few arbitrary small changes to a program at a time.
11
Mutation Testing
the
12
Mutation Testing
A mutated program:
If there exists at least one test case in the test suite for which:
13
Mutation Testing
can be automated by predefining a set of primitive changes that can be applied to the program.
14
Mutation Testing
15
Mutation Testing
very expensive,
16
them as logical relation between inputs and outputs. result is a Boolean graph representing the relationships
18
column of the decision table corresponds to a test case for functional testing.
19
Study the functional requirements. Mark and number all causes and effects. Numbered causes and effects:
become
20
Draw causes on the LHS Draw effects on the RHS Draw logical relationship between causes and effects
as to
21
22
A
C
24
25
Processing
The function calculates whether the level is safe, too high, or too low. message on screen
Output
26
27
28
valid.
29
Three effects
level level
= safe = high
invalid
syntax
30
E3
E2
31
S S
P
S
I A
X
X
A
A P
A
A P
A
A
P A
Effect 3
32
the example, there are five rows for causes and three for effects.
33
The columns of the decision table correspond to test cases. Define the columns by examining each effect:
by examining the lines flowing into the effect nodes of the graph.
34
Testing
Unit testing:
test the functionalities of a single module or function. test the interfaces among the modules. test the fully integrated system against its functional and non-functional requirements.
36
Integration testing:
System testing:
Integration testing
After different modules of a system have been coded and unit tested:
37
System Testing
System testing:
Validate
38
Integration Testing
bang approach
top-down
approach approach
bottom-up mixed
approach
39
rms Display-solution
Compute-solution
Get-data
Validate-data
40
the modules are simply put together and tested. technique is used only for very small systems.
41
If an error is found:
It is very difficult to localize the error The error may potentially belong to any of the modules being integrated.
Debugging errors found during big bang integration testing are very expensive to fix.
42
Integrate and test the bottom level modules first. A disadvantage of bottom-up testing:
43
Immediate subordinate modules of the 'skeleton are combined with it and tested.
44
Most
common approach
45
Integration Testing
In top-down approach:
testing
waits till all top-level modules are coded and unit tested. can start only after bottom level modules are ready.
46
In bottom-up approach:
testing
In phased integration,
A
group of related modules are added to the partially integrated system each time. degenerate case of the phased integration testing.
48
Big-bang testing:
A
System Testing
50
System Testing
Testing
Testing Testing
Acceptance
51
Alpha testing
52
Beta Testing
53
Acceptance Testing
54
System Testing
Non-functional
Performance Testing
There
56
Stress testing
Stress testing
also
57
Stress testing
to impose a range of abnormal and even illegal input conditions as to stress the capabilities of the software.
58
So
Stress Testing
testing evaluates system performance when all users or devices are busy simultaneously.
59
Stress Testing
60
Stress Testing
The maximum number of users active at any time, input data size, etc.
Volume Testing
data structures (e.g. queues, stacks, arrays, etc.) are large enough to handle all possible situations. Fields, records, and files are stressed to check if their size can accommodate all possible data volumes.
62
Configuration Testing
in various hardware and software configurations specified in the requirements sometimes systems are built in various configurations for different users for instance, a minimal system may serve a single user,
Compatibility Testing
These tests are needed when the system interfaces with other systems:
Check
64
65
Recovery Testing
Subject
Maintenance Testing
Maintenance Testing
Verify that:
all they
68
Documentation tests
guides,
maintenance technical
guides,
documents
69
Documentation tests
Documents
compliance
70
Usability tests
screens
messages report
navigation
Environmental test
These tests check the systems ability to perform at the installation site. Requirements might include tolerance for
heat
humidity
chemical presence portability electrical or magnetic fields disruption of power, etc.
72
73
Specifies:
how many tests have been applied to a subsystem, how many tests have been successful, how many have been unsuccessful, and the degree to which they have been unsuccessful,
e.g. whether a test was an outright failure or whether some expected results of the test were actually observed.
74
Regression Testing
Does not belong to either unit test, integration test, or system test.
In
75
Regression testing
Ensures
that no new bug has been introduced due to the change or the bug fix.
76
Regression testing
Always
77
Summary
mutation
78
Summary
derive test cases based on definition and use of data make arbitrary small changes see if the existing test suite detect these
Mutation testing:
Summary
Cause-effect graphing:
can
Decision
each
Summary
Integration testing:
Develop
82