Static
Testing
Introduction
• To check defects in software application without executing the
code.
• To avoid errors at an early stage of development
• Helps finding errors that may not be found by Dynamic Testing.
Two main types
• Manual examinations - REVIEWS.
• Automated analysis using tools
2
Testing Review
• Meeting conducted to find
• The potential defects in the design of any program.
• The team members get to know about the progress of the project and sometimes the
diversity of thoughts may result in excellent suggestions.
• Documents are directly examined by people and discrepancies are sorted out
Four parts:
• Informal reviews
• Walkthroughs
• Technical review
• Inspections
3
Types of participants
• Moderator: Performs entry check, follow up on rework, coaching team
member, schedule the meeting.
• Author: Takes responsibility for fixing the defect found and improves the
quality of the document
• Scribe: It does the logging of the defect during a review and attends the
review meeting
• Reviewer: Check material for defects and inspects
• Manager: Decide on the execution of reviews and ensures the review
process objectives are met.
4
Types of defects
• Deviations from standards
• Non-maintainable code
• Design defects
• Missing requirements
• Inconsistent interface specifications
5
What is Tested in Static Testing
• Unit Test Cases • Test Data
• Business Requirements Document • Traceability Matrix Document
(BRD) • User Manual/Training
• Use Cases Guides/Documentation
• System/Functional Requirements • Test Plan Strategy Document/Test
• Prototype Cases
• Prototype Specification Document • Automation/Performance Test
Scripts
• DB Fields Dictionary Spreadsheet
6
ADD A FOOTER 7
Summary:
• Static testing is to find defects as early as possible.
• Static testing not a substitute for dynamic testing, both find a
different type of defects
• Reviews are an effective technique for Static Testing
• Reviews not only help to find defects but also understand
missing requirements, design defects, non-maintainable code.
ADD A FOOTER 8
Static vs Dynamic Testing
• Static testing was done without executing the program whereas Dynamic testing is done
by executing the program.
• Static testing checks the code, requirement documents, and design documents to find
errors whereas Dynamic testing checks the functional behavior of software system,
memory/CPU usage and overall performance of the system.
• Static testing is about the prevention of defects whereas Dynamic testing is about finding
and fixing the defects.
• Static testing does the verification process while Dynamic testing does the validation
process.
• Static testing is performed before compilation whereas Dynamic testing is performed after
compilation.
• Static testing techniques are structural and statement coverage while Dynamic testing
techniques are Boundary Value Analysis & Equivalence Partitioning. 9
Model Based
Testing
Click icon to add picture
Model Based Testing
• Run time behavior of software under test is checked against predictions
made by a model
• Behavior can be described in terms of input sequences, actions,
conditions, output and flow of data from input to output
• Examples of the model are:
• Data Flow
• Control Flow
• Dependency Graphs
• Decision Tables
• State transition machines
ADD A FOOTER 11
Model Based Testing Example
ADD A FOOTER 12
Types of MBT:
• Two types of Model based testing framework.
• Offline / a priori:
• Generation of Test Suites before executing it.
• A test suiteCollection of test cases.
• Online / on-the-fly: Generation of Test Suites during
test execution
13
Different Models in Testing:
• Finite State Machines
ADD A FOOTER 14
• State Charts
ADD A FOOTER 15
• Unified Modeling Language (UML)
ADD A FOOTER 16