KEMBAR78
Software testing ppt | PPTX
R.POONKODI,
ASSISTANT PROFESSOR,
COMPUTER SCIENCE AND ENGINEERING,
SRI ESHWAR COLLEGE OF ENGINEERING,
COIMBATORE.
UNIT I INTRODUCTION
Testing as an Engineering Activity – Testing as a Process – Testing
axioms – Basic definitions – Software Testing Principles – The Tester’s
Role in a Software Development Organization – Origins of Defects –
Cost of defects – Defect Classes – The Defect Repository and Test
Design – Defect Examples – Developer/Tester Support of Developing
a Defect Repository – Defect Prevention strategies.
 People with software development skills are in demand.
 New methods, techniques, and tools are becoming
available to support development and maintenance
tasks.
 Poor quality software that can cause loss of life or
property is no longer acceptable to society.
 Failures can result in catastrophic losses.
 High qualified staff ensure that software products are
built on time, with in budget and are of the highest
quality with respect to attributes such as reliability,
correctness, usability and the ability to meet all user
requirements.
 The profession of a software engineering is slowly
emerging as a formal engineering disciplines.
 Using an engineering approach to software
development implies that:
 the development process is well understood;
 projects are planned;
 life cycle models are defined and adhered to;
 standards are in place for product and process;
 measurements are employed to evaluate product and
process quality;
 components are reused;
 validation and verification processes play a key role in
quality
 determination;
 engineers have proper education, training, and
certification.
Quality factors are
• Usability
• Testability
• Maintainability
• Reliability
 Project planning,
 Requirements management
 Development of formal specifications
 Structured design with use of information hiding and
encapsulation
 Design and code reuse.
 Inspections and reviews.
 Product and process measures
 Education and training of software professionals.
 Development and application of CASE tools
 Use of effective testing techniques.
 Integration of testing activities into the entire life cycle.
 Process, in the software engineering domain, is the
set of methods, practices, standards, documents,
activities, policies, and procedures that software
engineers use to develop and maintain a software
system and its associated artifacts, such as project
and test plans, design documents, code, and
manuals.
 CMM (Capability Maturity Model)
 SPICE
 BOOTSTRAP
 TMM(Testing Maturity Model)
 Verification:
"Are we building the product right?”
 The software should conform to its
specification.
 Validation:
"Are we building the right product?”
 The software should do what the user really
requires.
Validation:
 Validation is the process of evaluating a software
system or component during, or at the end of,
the development cycle in order to determine
whether it satisfies specified requirements.
Verification:
 Verification is the process of evaluating a
software system or component to determine
whether the products of a given development
phase satisfy the conditions imposed at the start
of that phase.
 Testing is a group of procedures carried out to
evaluate some aspect of a piece of software.
 Testing is a process used for revealing defects in
software, and for establishing that the software has
attained a specified degree of quality with respect
to selected attributes.
 Debugging, or fault localization is the process
of
(1) locating the fault or defect,
(2) repairing the code, and
(3) retesting the code.
Errors:
 An error is a mistake, misconception, or
misunderstanding on the part of a software
developer.
Faults (Defects) :
 A fault (defect) is introduced into the software as the
result of an error. It is an anomaly in the software
that may cause it to behave incorrectly, and not
according to its specification.
Failures:
 A failure is the inability of a software system or
component to perform its required functions within
specified performance requirements.
 A test case in a practical sense is a test-related item
which contains the following information:
1. A set of test inputs. These are data items received
from an external source by the code under test. The
external source can be hardware, software, or
human.
2. Execution conditions. These are conditions required
for running the test, for example, a certain state of
a database, or a configuration of a hardware device.
3. Expected outputs. These are the specified results to
be produced by the code under test.
Test or Test set
 A test is a group of related test cases, or a group of related test cases and
test procedures
 Group of related tests that are associated with database and are usually
run together is sometimes called as test suite.
Test Oracle:
 A test oracle is a document, or piece of software that allows testers to
determine whether a test has been passed or failed.
Test Bed:
 A test bed is an environment that contains all the hardware and software
needed to test a software component or a software system.
Software Quality:
 Quality relates to the degree to which a
system, system component, or process meets
specified requirements.
 Quality relates to the degree to which a
system, system component, or process meets
customer or user needs, or expectations.
Metric :
 A metric is a quantitative measure of the degree
to which a system, system component, or
process possesses a given attribute.
 Product metric :
 software size
 LOC
 Process metric:
 Costs
 Time
Quality metric :
 A quality metric is a quantitative measurement of the
degree to which an item possesses a given quality
attribute.
Quality Attributes :
• Correctness
• Reliability
• Usability
• Integrity
• Portability
• Maintainability
• Interoperability
Software Quality Assurance Group:
 The software quality assurance (SQA)
group is a team of people with the
necessary training and skills to ensure
that all necessary actions are taken
during the development process so that
the resulting software conforms to
established technical requirements.
Reviews :
 A review is a group meeting whose
purpose is to evaluate a software artifact
or a set of software artifacts.
 A principle can be defined as:
1. a general or fundamental, law, doctrine, or
assumption;
2. a rule or code of conduct;
3. the laws or facts of nature underlying the working
of an artificial device.
 Principle 1. Testing is the process of exercising a
software component using a selected set of test
cases with the intent of (i) revealing defects,
and (ii) evaluating quality.
 Principle 2. When the test objective is to detect
defects, then a good test case is one that has a
high probability of revealing a yet undetected
defect(s).
 Principle 3. Test results should be inspected
meticulously.
 Principle 4. A test case must contain the
expected output or result.
 Principle 5. Test cases should be developed
for both valid and invalid input conditions.
 Principle 6. The probability of the existence
of additional defects in a software
component is proportional to the number of
defects already detected in that component.
 Principle 7. Testing should be carried out by
a group that is independent of the
development group.
 Principle 8. Tests must be repeatable and
reusable.
 Principle 9. Testing should be planned.
 Principle 10. Testing activities should be
integrated into the software life cycle.
 Principle 11. Testing is a creative and
challenging task.
 The tester’s job is
 reveal defects
 find weak points,
 inconsistent behavior,
 circumstances where the software does not work as
expected.
• cooperating with code developers.
• work along with requirements engineers.
• work with designers to plan for integration
and unit test.
• test managers will need to cooperate with project
managers to develop reasonable test plans.
 Defect hypotheses include,
 design test cases;
 design test procedures;
 assemble test sets;
 select the testing levels (unit, integration, etc.) appropriate
for the tests;
 evaluate the results of the tests.
 A successful testing experiment will prove the
hypothesis is true,
 that is, the hypothesized defect was present. Then the
software can be repaired (treated).
 fault model:
 A fault (defect) model is a link between the error
made (e.g., a missing requirement, a
misunderstood design element, a typographical
error), and the fault/defect in the software.
Defect Classes :
• Requirement/Specification Defect Classes
• Design Defect Classes
• Coding Defect Classes
• Testing Defect Classes
 Pre condition
 Post condition
 Functional description
 Interface description
 Code defect
 Data defect
 Algorithmic and processing defect
 External Interface defect
 Control, logic, and sequence defects
 Algorithmic and processing defects
 Data Flow defects
 Data Defects
 External Hardware, Software Interface
Defects
 Code Documentation Defects
 The cost of defects can be measured by the
impact of the defects and when we find
them. Earlier the defect is found lesser is the
cost of defect.
 But if the error is not caught in the
specifications and is not found till the user
acceptance then the cost to fix those errors
or defects will be way too expensive.
1. The Stakeholder Axiom
2. The Test Basis
3. The Test Oracle Axiom
4. Fallibility
5. The Scope Management Axiom
6. The Coverage Axiom
7. The Delivery Axiom
8. The Environment Axiom
9. The Event Axiom
10. The Prioritization Axiom
11. The Execution Sequencing Axiom
12. The Design Axiom
13. The Repeat-Test Axiom
14. Good enough
15. Never finished.
16. Value.
 Defect Prevention (DP) is a strategy applied to the software
development life cycle that identifies root causes of defects and
prevents them from recurring. It is the essence of Total Quality
Management (TQM). DP, identified by the Software Engineering
Institute as a level 5 Key Process Area (KPA) in the Capability
Maturity Model (CMM), involves analyzing defects encountered in
the past and specifying checkpoints and actions to prevent the
occurrence of similar defects in the future. In general, DP
activities are a mechanism for propagating the knowledge of
lessons learned between projects.
 Mature IT organizations have an established software process to
carry out their responsibilities. This process is enhanced when DP
methodologies are implemented to improve quality and
productivity and reduce development costs. Figure 1 clearly
depicts that identifying defects late in the game is costly.
Software Defect Rate Of Discovery Versus Time
TMM
involves
commitment
and ability to
perform
activities and
tasks related
to improving
testing
capability
encompasses the
technical
activities and
tasks that, when
applied,
constitute quality
testing practices
defined as a
cooperating,
or
supporting,
view
Software testing ppt

Software testing ppt

  • 2.
    R.POONKODI, ASSISTANT PROFESSOR, COMPUTER SCIENCEAND ENGINEERING, SRI ESHWAR COLLEGE OF ENGINEERING, COIMBATORE.
  • 3.
    UNIT I INTRODUCTION Testingas an Engineering Activity – Testing as a Process – Testing axioms – Basic definitions – Software Testing Principles – The Tester’s Role in a Software Development Organization – Origins of Defects – Cost of defects – Defect Classes – The Defect Repository and Test Design – Defect Examples – Developer/Tester Support of Developing a Defect Repository – Defect Prevention strategies.
  • 4.
     People withsoftware development skills are in demand.  New methods, techniques, and tools are becoming available to support development and maintenance tasks.  Poor quality software that can cause loss of life or property is no longer acceptable to society.  Failures can result in catastrophic losses.  High qualified staff ensure that software products are built on time, with in budget and are of the highest quality with respect to attributes such as reliability, correctness, usability and the ability to meet all user requirements.  The profession of a software engineering is slowly emerging as a formal engineering disciplines.
  • 5.
     Using anengineering approach to software development implies that:  the development process is well understood;  projects are planned;  life cycle models are defined and adhered to;  standards are in place for product and process;  measurements are employed to evaluate product and process quality;  components are reused;  validation and verification processes play a key role in quality  determination;  engineers have proper education, training, and certification.
  • 7.
    Quality factors are •Usability • Testability • Maintainability • Reliability
  • 8.
     Project planning, Requirements management  Development of formal specifications  Structured design with use of information hiding and encapsulation  Design and code reuse.  Inspections and reviews.  Product and process measures  Education and training of software professionals.  Development and application of CASE tools  Use of effective testing techniques.  Integration of testing activities into the entire life cycle.
  • 9.
     Process, inthe software engineering domain, is the set of methods, practices, standards, documents, activities, policies, and procedures that software engineers use to develop and maintain a software system and its associated artifacts, such as project and test plans, design documents, code, and manuals.
  • 11.
     CMM (CapabilityMaturity Model)  SPICE  BOOTSTRAP  TMM(Testing Maturity Model)
  • 13.
     Verification: "Are webuilding the product right?”  The software should conform to its specification.  Validation: "Are we building the right product?”  The software should do what the user really requires.
  • 15.
    Validation:  Validation isthe process of evaluating a software system or component during, or at the end of, the development cycle in order to determine whether it satisfies specified requirements. Verification:  Verification is the process of evaluating a software system or component to determine whether the products of a given development phase satisfy the conditions imposed at the start of that phase.
  • 16.
     Testing isa group of procedures carried out to evaluate some aspect of a piece of software.  Testing is a process used for revealing defects in software, and for establishing that the software has attained a specified degree of quality with respect to selected attributes.
  • 17.
     Debugging, orfault localization is the process of (1) locating the fault or defect, (2) repairing the code, and (3) retesting the code.
  • 18.
    Errors:  An erroris a mistake, misconception, or misunderstanding on the part of a software developer. Faults (Defects) :  A fault (defect) is introduced into the software as the result of an error. It is an anomaly in the software that may cause it to behave incorrectly, and not according to its specification. Failures:  A failure is the inability of a software system or component to perform its required functions within specified performance requirements.
  • 19.
     A testcase in a practical sense is a test-related item which contains the following information: 1. A set of test inputs. These are data items received from an external source by the code under test. The external source can be hardware, software, or human. 2. Execution conditions. These are conditions required for running the test, for example, a certain state of a database, or a configuration of a hardware device. 3. Expected outputs. These are the specified results to be produced by the code under test.
  • 20.
    Test or Testset  A test is a group of related test cases, or a group of related test cases and test procedures  Group of related tests that are associated with database and are usually run together is sometimes called as test suite. Test Oracle:  A test oracle is a document, or piece of software that allows testers to determine whether a test has been passed or failed. Test Bed:  A test bed is an environment that contains all the hardware and software needed to test a software component or a software system.
  • 21.
    Software Quality:  Qualityrelates to the degree to which a system, system component, or process meets specified requirements.  Quality relates to the degree to which a system, system component, or process meets customer or user needs, or expectations.
  • 22.
    Metric :  Ametric is a quantitative measure of the degree to which a system, system component, or process possesses a given attribute.  Product metric :  software size  LOC  Process metric:  Costs  Time
  • 23.
    Quality metric : A quality metric is a quantitative measurement of the degree to which an item possesses a given quality attribute. Quality Attributes : • Correctness • Reliability • Usability • Integrity • Portability • Maintainability • Interoperability
  • 24.
    Software Quality AssuranceGroup:  The software quality assurance (SQA) group is a team of people with the necessary training and skills to ensure that all necessary actions are taken during the development process so that the resulting software conforms to established technical requirements. Reviews :  A review is a group meeting whose purpose is to evaluate a software artifact or a set of software artifacts.
  • 25.
     A principlecan be defined as: 1. a general or fundamental, law, doctrine, or assumption; 2. a rule or code of conduct; 3. the laws or facts of nature underlying the working of an artificial device.
  • 26.
     Principle 1.Testing is the process of exercising a software component using a selected set of test cases with the intent of (i) revealing defects, and (ii) evaluating quality.  Principle 2. When the test objective is to detect defects, then a good test case is one that has a high probability of revealing a yet undetected defect(s).  Principle 3. Test results should be inspected meticulously.
  • 27.
     Principle 4.A test case must contain the expected output or result.  Principle 5. Test cases should be developed for both valid and invalid input conditions.  Principle 6. The probability of the existence of additional defects in a software component is proportional to the number of defects already detected in that component.
  • 28.
     Principle 7.Testing should be carried out by a group that is independent of the development group.  Principle 8. Tests must be repeatable and reusable.  Principle 9. Testing should be planned.  Principle 10. Testing activities should be integrated into the software life cycle.
  • 29.
     Principle 11.Testing is a creative and challenging task.
  • 30.
     The tester’sjob is  reveal defects  find weak points,  inconsistent behavior,  circumstances where the software does not work as expected. • cooperating with code developers. • work along with requirements engineers. • work with designers to plan for integration and unit test. • test managers will need to cooperate with project managers to develop reasonable test plans.
  • 32.
     Defect hypothesesinclude,  design test cases;  design test procedures;  assemble test sets;  select the testing levels (unit, integration, etc.) appropriate for the tests;  evaluate the results of the tests.
  • 33.
     A successfultesting experiment will prove the hypothesis is true,  that is, the hypothesized defect was present. Then the software can be repaired (treated).  fault model:  A fault (defect) model is a link between the error made (e.g., a missing requirement, a misunderstood design element, a typographical error), and the fault/defect in the software.
  • 34.
    Defect Classes : •Requirement/Specification Defect Classes • Design Defect Classes • Coding Defect Classes • Testing Defect Classes
  • 37.
     Pre condition Post condition  Functional description  Interface description
  • 39.
     Code defect Data defect  Algorithmic and processing defect  External Interface defect
  • 41.
     Control, logic,and sequence defects  Algorithmic and processing defects  Data Flow defects  Data Defects  External Hardware, Software Interface Defects  Code Documentation Defects
  • 42.
     The costof defects can be measured by the impact of the defects and when we find them. Earlier the defect is found lesser is the cost of defect.  But if the error is not caught in the specifications and is not found till the user acceptance then the cost to fix those errors or defects will be way too expensive.
  • 45.
    1. The StakeholderAxiom 2. The Test Basis 3. The Test Oracle Axiom 4. Fallibility 5. The Scope Management Axiom 6. The Coverage Axiom 7. The Delivery Axiom 8. The Environment Axiom 9. The Event Axiom 10. The Prioritization Axiom 11. The Execution Sequencing Axiom 12. The Design Axiom 13. The Repeat-Test Axiom 14. Good enough 15. Never finished. 16. Value.
  • 46.
     Defect Prevention(DP) is a strategy applied to the software development life cycle that identifies root causes of defects and prevents them from recurring. It is the essence of Total Quality Management (TQM). DP, identified by the Software Engineering Institute as a level 5 Key Process Area (KPA) in the Capability Maturity Model (CMM), involves analyzing defects encountered in the past and specifying checkpoints and actions to prevent the occurrence of similar defects in the future. In general, DP activities are a mechanism for propagating the knowledge of lessons learned between projects.  Mature IT organizations have an established software process to carry out their responsibilities. This process is enhanced when DP methodologies are implemented to improve quality and productivity and reduce development costs. Figure 1 clearly depicts that identifying defects late in the game is costly.
  • 47.
    Software Defect RateOf Discovery Versus Time
  • 50.
    TMM involves commitment and ability to perform activitiesand tasks related to improving testing capability encompasses the technical activities and tasks that, when applied, constitute quality testing practices defined as a cooperating, or supporting, view