Why Static instead of Dynamic and why teams do static testing? What’s
the secret behind?
Yes, we have answer!!!!
Static Testing helps you build the Product Right, Yes a
process of Verification.
Static testing is an analysis of a program carried out without
executing the program. During static testing, you have a checklist to check
whether the work you are doing is going as per the set standards of the
organization.
Why is static testing more effective?
Static testing gives you wide-ranging
diagnostics for your code and warns you about:
Syntax errors
Code that will be hard to maintain
Code that will be hard to test
Code
that does not conform to your coding standards
Non-portable usage
ANSI
violations
All this takes place before compilation. It takes
roughly as long as compilation and checks every statement you have written.
Since static testing is faster and
achieves 100% coverage, the unit cost of detecting these bugs by static testing
is many times lower than by dynamic testing
If you are using neither static nor dynamic test
tools, static tools offer greater insignificant benefits.
If company can afford only one tool,
remember: Static testing is up to 100 times more effective. Even in selective
testing, static testing may be up to 10 times more effective.
Dynamic testing detects fewer errors
than static testing, but it does detect some that static testing misses.
Cost-Effectiveness of Static vs.
Dynamic Analysis:
Static Testing Techniques :
Here are some of
the more popular and effective techniques used
• Inspection
•
Walkthrough
• Review
Inspection - Main purpose: Find defects
• Formal
individual and group checking, using sources and standards, According to
detailed and specific rules
• Inspection
is a well-defined process
Inspection: An inspection is a formal, rigorous,
in-depth group review designed to identify problems as close to their point of
origin as possible. Inspection is a recognized industry best practice to
improve the quality of a product and to improve productivity, Inspections is a
formal review and generally need is predefined at the start of the product
planning,
The objectives of the inspection process are to
• Find
problems at the earliest possible point in the software development process
• Verify
that the work product meets its requirement
• Ensure
that work product has been presented according to predefined standards
• Provide
data on product quality and process effectiveness
•
Inspection advantages are to build technical knowledge and skill among team
members by reviewing the output of other people
• Increase
the effectiveness of software testing.
IEEE 1028 recommends three following roles in an Inspection:
Inspector Leader: The
inspection leader shall be responsible for administrative tasks pertaining to
the inspection, shall be responsible for planning and preparation, shall ensure
that the inspection is conducted in an orderly manner and meets its objectives,
should be responsible for collecting inspection data
Recorder: The recorder should record
inspection data required for process analysis. The inspection leader may be the
recorder.
Reader: The reader shall lead the
inspection team through the software product in a comprehensive and logical
fashion, interpreting sections of the work product and highlighting important
aspects
Author: The author shall be
responsible for the software product meeting its inspection entry criteria, for
contributing to the inspection based on special understanding of the software
product, and for performing any rework required to make the software product
meet its inspection exit criteria.
Inspector: Inspectors shall identify and
describe anomalies in the software product. Inspectors shall be chosen to
represent different viewpoints at the meeting (for example, sponsor,
requirements, design, code, safety, test, independent test, project management,
quality management, and hardware engineering). Only those viewpoints pertinent to
the inspection of the product should be present. Some inspectors should
be assigned specific review topics to ensure effective coverage. For example,
one inspector may focus on conformance with a specific standard or standards,
another on syntax, and another for overall coherence. These roles should be
assigned by the inspection leader when planning the inspection.
All participants in the review are inspectors. The author shall not act
as inspection leader and should not act as reader or recorder. Other roles may
be shared among the team members. Individual participants may act in more than
one role. Individuals holding management positions over any member of the
inspection team shall not participate in the inspection
Walkthrough - Main purpose: Understanding
• Author
guides the group through a document, so all understand the same thing,
consensus on changes to make
Walkthrough: Method of conducting informal
group/individual review is called walkthrough, in which a designer or
programmer leads members of the development team and other interested parties
through a software product, and the participants ask questions and make
comments about possible errors, violation of development standards, and other
problems or may suggest improvement on the article, walkthrough can be pre
planned or can be conducted at need basis and generally people working on the
work product are involved in the walkthrough process.
The Purpose of walkthrough is to
• Find
problems
• Discuss
alternative solutions
Focusing on demonstrating how work product meets all requirements. IEEE
1028 recommends three specialist roles in a walkthrough:
Leader: who conducts the walkthrough,
handles administrative tasks, and ensures orderly conduct (and who is often the
Author)
Recorder: who notes all anomalies
(potential defects), decisions, and action items identified during the
walkthrough meeting, normally generate minutes of meeting at the end of
walkthrough session.
Author: who presents the software
product in step-by-step manner at the walk-through meeting, and is probably
responsible for completing most action items.
Walkthrough Process: Author
describes the artifact to be reviewed to reviewers during the meeting.
Reviewers present comments, possible defects, and improvement suggestions to
the author. Recorder records all defect, suggestion during walkthrough meeting.
Based on reviewer comments, author performs any necessary rework of the work
product if required. Recorder prepares minutes of meeting and sends the
relevant stakeholders and leader is normally to monitor overall walkthrough
meeting activities as per the defined company process or responsibilities for
conducting the reviews, generally performs monitoring activities, commitment
against action items etc.
Review - Main purpose: Decision making
• Group
discusses document and makes a decision about the content, e.g. how something
should be done, go or no-go decision
Review is "A process or meeting during
which artifacts of software product are examined by project stockholders, user
representatives, or other interested parties for feedback or approval”.
Software Review can be on Technical specifications, designs, source code, user
documentation, support and maintenance documentation, test plans, test
specifications, standards, and any other type of specific to work product, it
can be conducted at any stage of the software development life cycle.
Purpose of conducting review is to minimize the defect ratio as early as
possible in Software Development life cycle. As a general principle, the
earlier a document is reviewed, the greater will be the impact of its defects
on any downstream activities and their work products. Magnitude cost of defect
fixing after the release of the product is around 60-100x. Review can be formal
or informal. Informal reviews are referred as walkthrough and formal as
Inspection.
·
Formal individual and group checking,
using sources and standards, According to detailed and specific rules
·
Inspection is a well-defined process
Conclusion:
Static testing finds bugs before you
compile.
Many bugs found by dynamic testing
can be found earlier by static testing.
The earlier you detect bugs the
cheaper they are to fix.
Static testing is more cost effective than dynamic
testing.
Source:
Software testing: testing across the entire software development life
cycle By
Gerald D. Everett, Raymond McLeod