Software Testing Basics
Software Testing Basics
Prepared by:Raghav
Target Audience
Beginners
Intermediate
What do we cover?
Basics of testing
Levels of Testing
Testing techniques
Software testing
Relative cost
per defect
125
100
75
50
25
Points to Ponder:
80% of all defects occur in 20% of the work
Test strategies impact test costs
Conversion of testing from craft to process can
give extensive benefits
Software Testing
Optimism
Belief that the system works
Negative attitude towards effective testing
Conflict between testers and developers
Testing is expensive
Delivery commitments
The V Model
What is V model?
The V Model
Customer Acceptance
Requirements
System
validation
Software
Requirements testing
Architecture (HLD) Integration
testing
Detailed Design Unit testing
(LLD)
Code
Testing v/s Life Cycle
Stage Test Activity
Requirements Acceptance Test ,System Test
NO!!
Even if we use other methods, cannot do away
with testing
Review, inspect, read, walkthrough, better
methodologies
And then TEST
TESTING
Process of executing a program with an intent of
finding an error
A good test case is one that has a high probability
of finding an as yet undiscovered error
A successful test is one that uncovers an as yet
undiscovered error
Testing Involves
•Testplan
•Generate test conditions, cases
•Create required test environment
•Execute tests by
Initiating
application under test
Applying inputs that are specified in the already
fault!
Definitions
•Defect
A deviation from specification or standard
Anything that causes customer dissatisfaction
Verification
All QC activities throughout the life cycle that ensure that
interim deliverables meet their input specification
Validation
The ‘test phase’ of the life cycle which assures that the
end product meets the user’s needs
Debugging
• Black Box
• White Box
• Basis path testing
Black box testing
Incorrect or missing functions
Interface errors
Errors in data structures and external database
access
Behaviour or performance errors
Initialisation and termination errors
Types of Black box testing
Equivalence partitioning
Special value
BVA(Boundary Value Analysis)
What is BVA?
Boundary value analysis (two variables)
X2
d a<=x1 <=b
c<=x2 <=d
X1
a b
BVA
Great number of errors tends to occur at the
boundaries of the input domain rather than
in the ‘center’
BVA leads to a selection of test cases that
exercise bounding values
Equivalence partitioning
● Wrong parameters
Integration test approach
• Top down
• Bottom up
• Sandwich M0
M31
Top down integration
M31
Bottom – up integration
• Construction and
testing with atomic
modules
• Stubs are NOT
needed
• Drivers are needed
Integration testing – some thoughts
• How to choose integration
order – incremental
What to check for ….
• May be based on
criticality of • Interface integrity
interfaces/module • Functional validity
• Risk reduction principle • Information content
may be used
• Performance
• Critically based on ..
- Module used by lot of
other modules
- Module has high
cyclomatic complexity
- Has special non-
functional (e.g,
performance)
requirements
System testing
project plan
Test Plan
Exercise
Prepare a checklist for testing
IV & V
What is Independent Verification & Validation?