7b. Software Testing
7b. Software Testing
Software Testing
http://www.cs. mu.edu/~kelgazza/
Strategic Approach
• Testing begins at the component level and works
"outward" toward the integration of the entire
computer-based system.
• Different testing techniques are appropriate for
different software engineering approaches and at
different points in time.
• Testing is conducted by the developer of the software
and (for large projects) an independent test group.
• Testing and debugging are different activities, but
debugging must be accommodated in any testing
strategy.
V&V
System engineering
Analysis modeling
Design modeling
Integration test
Validation test
System test
Testing Strategy – V-Model
• Disciplined
• Requirements
are known
• Small projects
• Easy to
understand
Testing Strategy
module
to be
tested
results
software
engineer
test cases
Unit Testing
module
to be
tested
interface
boundary conditions
independent paths
error handling paths
test cases
Unit Test Environment
driver
interface
local data structures
stub stub
test cases
RESULTS
Integration Testing Strategies
Options:
• the “big bang” approach
(typically results in chaos)
• an incremental construction strategy
Incremental approach: Top Down Integration
Top Down Integration
A
top module is tested with
stubs
B F G
B F G
A
Top modules are
tested with stubs
B F G
cluster
Regression Testing
• Regression testing is the re-execution of some subset of
tests that have already been conducted to ensure that
changes have not propagated unintended side effects
• Whenever software is corrected, some aspect of the
software configuration (the program, its documentation,
or the data that support it) is changed.
• Regression testing helps to ensure that changes (due to
testing or for other reasons) do not introduce unintended
behavior or additional errors.
• Regression testing may be conducted manually, by re-
executing a subset of all test cases or using automated
capture/playback tools.
Smoke Testing
• It is to verify quickly that the software product
works without using pre-design test cases.
• The test validate the following:
–Version, configuration, data, and system
navigability.
• To verify the test:
–Execute reports, queries, add new data, and the
most relevant transitions.
General Testing Criteria
22