You are on page 1of 34

Software Quality Assurance

(SQA) - SWE 401

Introduction and Definitions


What is Software Quality?

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Outline
• What is Software?
• Software errors, faults and failures
• Classification of the causes of software errors
• What is quality?
• Software quality – definition
• Software quality assurance – definition and objectives
• Software quality assurance and software engineering

Galin, SQA from theory to implementation © Pearson Education Limited 2004


After completing this chapter, you will
be able to:
• Define software, software quality and software quality
assurance.
• Distinguish between software errors, software faults and
software failures.
• Identify the various causes of software errors.
• Explain the objectives of software quality assurance activities.
• Explain the relationship between software quality assurance
and software engineering.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


What is Software?
Based on IEEE definition, software is:

Computer programs, procedures, and possibly


associated documentation and data pertaining to the
operation of a computer system.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Errors, Faults and Failures
• “We’ve used the Simplex HR software in our Human Resources
Department for about three years and we have never had a software
failure.”

• “I started to use Simplex HR two months ago; we had so many failures


that we are considering replacing the software package.”

• “We have been using the same software package for almost four years.
We were very satisfied throughout the period until the last few months,
when we suddenly faced several severe failures. The Support Center of
the software house from which we bought the package claims that they
have never encountered failures of the type we experienced even though
they serve about 700 customers who utilize Simplex HR.”

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Errors, Faults and Failures
• Software Error – Made by the programmer
- Syntax (grammatical) error.
- Logic error (multiply instead of adding two operands).
• Software Fault –
- All software errors may not cause software faults.
- That part of the software may not be executed
• Software Failures – Here’s the interest.
- A software fault becomes a software failure when/if it is activated.
- Faults may be found in the software due to the way the software is
executed
- Other constraints on the software’s execution, such as execution
options.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Example: The “Meteoro-X” meteorological
equipment firmware
The software requirements for “Meteoro-X” meteorological
equipment firmware (software embedded in the product) were
meant to block the equipment’s operation when its internal
temperature rose above 60°C. A programmer error resulted in a
software fault when the temperature limit was coded as 160°.
This fault could cause damage when the equipment was
subjected to temperatures higher than 60°. Because the
equipment was used only in those coastal areas where
temperatures never exceeded 60°, the software fault never
turned into a software failure.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Errors, Faults and Failures

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Classification of the Causes of Software
Errors
1. Faulty requirements definition.
e.g., erroneous definition of requirements, absence of vital requirements, …

1. Client-developer communication failures.


e.g., misunderstanding of client’s instructions, misunderstanding of client’s written
changes requirements, misunderstanding of client’s responses, ...

1. Deliberate deviations from software requirements.


e.g., reusing already built software modules, omitting required functions due to
time/budget constraints, …

1. Logical design errors.


e.g., erroneous algorithms, process sequencing errors, erroneous of boundary
conditions, ...
Galin, SQA from theory to implementation © Pearson Education Limited 2004
Classification of the Causes of Software
Errors
5. Coding errors.
6. Non-compliance with documentation and coding instructions.
e.g., difficulties in understanding “non-complying” code, difficulties in reviewing
non-complying team design, difficulties in testing non-complying module, ...

5. Shortcomings of the testing process.


e.g., incomplete test plan, failure to report errors and faults, …

5. User interface and procedure errors.


6. Documentation errors.
e.g., omission of software functions, listing non-existing functions, …

Galin, SQA from theory to implementation © Pearson Education Limited 2004


What is Quality?
Two different views:

1. Quality popular view:


- Something “good” but not quantifiable.
- Something luxury and classy.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


What is Quality?
2. Quality professional view:
a. ISO 8402 definition of quality:
The totality of features and characteristics of a product or a service that
bear on its ability to satisfy stated or implied needs.

b. Conformance to requirement (Crosby, 1979):


i. The requirements are clearly stated and the product must conform to
it.
ii. Any deviation from the requirements is regarded as a defect.
iii. A good quality product contains fewer defects.

c. Fitness for use (Juran, 1970):


i. Fit to user expectations: meet user’s needs and satisfaction.
ii. A good quality product provides better user satisfaction.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


What is Quality?
Three level of organizations are aimed at maintaining the
production of quality:

1. Quality Management (QM).


The assembly and management of all activities aimed at the
production of quality by organizations of various kinds.
1. Quality Assurance (QA).
Proper Quality Management implies consequent implementation of
Quality Assurance.
1. Quality Control (QC).
A major part of the quality assurance is the Quality Control.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Engineers and Quality
• Software engineers strive to control the

1. Process applied: What is the best process (i.e SDLC) to


be used for the development of software.
2. Resources expended: Make sure software development is
finished in expected time and also using the estimated
budget.
3. End product quality attributes: Make sure that the
software itself is of a high quality and contains all features
and requirements (functional and non-functional).

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Quality – IEEE Definition

Software quality is:

1. The degree to which a system, component, or process meets


specified requirements. (Crosby, 1979)
2. The degree to which a system, component, or process meets
customer or user needs or expectations. (Juran, 1970)

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Quality – IEEE Definition
Each definition reflects a different conception of software
quality:
1. “Quality means conformance to requirements” (Crosby, 1979).
2. “(1) Quality consists of those product features which meet the
needs of customers and thereby provide product satisfaction.
(2) Quality consists of freedom from deficiencies” (Juran,
1988).

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Other Definition and Concept
Four absolutes of quality management:

• Quality Means Conformance to Requirements. Both


functional and non-functional.
• Quality Comes from Prevention, not detection.
• Quality is never ending improvement.
• Quality is Zero Defects.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Prevention Versus Detection

• Detection:
Defects/errors are noticed afterwards (identified) and are then corrected.

• Prevention:
Keeping defects from happening in the first place, through checks and
other restrictions [Do it right from the first time].

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Quality Perspectives
Software quality can be seen from different perspectives:

• Customer:
Complete requirements (Functional and non-functional).
• Project manager:
Cost and schedule.
• Maintenance engineer:
Detection and correction times.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Benefits of Software Quality

• Decreased number of defects and errors in software.


• Less rework as a result of less software defects.
• Reduced development and maintenance cost.
• Increased software reliability.
• Increased customer satisfaction.
• Happier software practitioners.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


SQA – Expanded Definition
Software quality assurance is:
A systematic, planned set of actions necessary to provide
adequate confidence that the software development process or the
maintenance process of a software system product conforms to
established functional technical requirements as well as with the
managerial requirements of keeping the schedule and operating
within the budgetary confines.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


The Objectives of SQA Activities in
Software Development
Software development (process-oriented):
1. Assuring, with acceptable levels of confidence, conformance
to functional technical requirements.
2. Assuring, with acceptable levels of confidence, conformance
to managerial requirements of scheduling and budgets.
3. Initiating and managing activities for the improvement and
greater efficiency of software development and SQA
activities.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Software Quality Assurance and
Software Engineering
• Software engineering is the application of a systematic,
disciplined, quantifiable approach to the development, operation
and maintenance of software.

• The characteristics of software engineering, especially its


systematic, disciplined and quantitative approach, make software
engineering a good environment for achieving SQA objectives.

• It is commonly accepted that cooperation between software


engineers and the SQA team is the way to achieve efficient and
economic development and maintenance activities that, at the same
time, assure the quality of the products of these activities.
Galin, SQA from theory to implementation © Pearson Education Limited 2004
Software Quality should be Considered
in:
• Infrastructure and tools.
• Staff.
• Contract.
• SDLC ( Requirements, design, implementation, …).
• Budget.
• Schedule.
• Maintenance.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Several disasters because of
inadequate software quality !!

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Patriot Missile System

• On February 25, 1991, the Patriot missile battery in Dharan, Saudi


Arabia had been in operation for 100 hours, by which time the system's
internal clock had drifted by one third of a second. For a target moving
as fast, this was equivalent to a position error of 600 meters.
• The radar system had successfully detected the Scud and predicted
where to look for it next, but because of the time error, looked in the
wrong part of the sky and found no missile. With no missile, the initial
detection was assumed to be a false track and the missile was removed
from the system. No interception was attempted, and the missile
impacted on a barracks killing 28 soldiers.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Summary
• Define software, software quality and software quality
assurance.
• Distinguish between software errors, software faults and
software failures.
• Identify the various causes of software errors.
• Explain the objectives of SQA activities.
• Explain the relationship between software quality assurance
and software engineering.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Case Study

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Denver International Airport Baggage
Handling System
The opening of the new Denver International Airport (DIA) in
February 1995 was a day of celebration for Colorado citizens but
it was certainly the end of a stressful period for the information
technology industry. DIA was planned to be the largest airport in
the United States, to serve 110,000,000 passengers annually by
2020, to handle 1750 flights daily through 200 gates and 12
operating runways. Operations at DIA were delayed by 16
months, mainly due to the failure of the software-based baggage
handling system, causing estimated total losses of $2 billion.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Denver International Airport Baggage
Handling System
Moreover, the baggage handling system finally put into service
was substantially downscaled in comparison to the system
originally specified. Although several other colossal failures of
software systems unfortunately have been recorded since 1995,
the failure of IT technology at DIA was especially traumatic to
the profession, whether due to the scale of the losses or the public
interest and criticism it raised. Many SQA professionals,
including the author, believe that had appropriate software quality
assurance systems been applied to the project at its start, a failure
of this scale would not have occurred or, at least, its losses would
have been dramatically reduced.
Galin, SQA from theory to implementation © Pearson Education Limited 2004
Tutorial

Error, Fault Failure Example

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Code
public static int numZero (int[] x)
{
//Effects: if x == null throw NullPointerException
// else return the number of occurrences of 0 in x
int count = 0;
for ( i = 1 ; i < x.length ; i++)
{
if (x[i] == 0)
count ++;
}
return count;
}

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Questions
● What is the error?
● i = 1, arrays in Java should start at index 0

● What is the result if x is [2, 7, 0]?

● count = 1, fault but not failure.

● What is the result if x is [0, 7, 2]?

● count = 0, fault results in failure.

Galin, SQA from theory to implementation © Pearson Education Limited 2004


Another Example
• A programmer may make an error in analyzing an algorithm (logical
design error).
• This may result in writing a code fault, say a reference to an incorrect
variable.
• When the program is executed, it may fail for some inputs in the domain
of the specification (failure).

Galin, SQA from theory to implementation © Pearson Education Limited 2004

You might also like