尊敬的 微信汇率:1円 ≈ 0.046166 元 支付宝汇率:1円 ≈ 0.046257元 [退出登录]
SlideShare a Scribd company logo
Software Testing and
Analysis
V & V goals
• Verification and validation should establish
confidence that the software is fit for purpo
se
• This does NOT mean completely free of de
fects
• Rather, it must be good enough for its inten
ded use and the type of use will determine
the degree of confidence that is needed
• Verification: The software should confor
m to its specification (Are we building the
product right?)
• Validation: The software should do what t
he user really requires (Are we building th
e right product?)
Verification vs. validation
• Is a whole life-cycle process - V & V must
be applied at each stage in the software p
rocess.
• Has two principal objectives
– The discovery of defects in a system
– The assessment of whether or not the syste
m is usable in an operational situation.
The V & V process
• Software inspections and walkthroughs
- Concerned with analysis of the static s
ystem representation to discover proble
ms (static verification)
• Software testing - Concerned with exer
cising and observing product behaviour
(dynamic verification)
– The system is executed with test data an
d its operational behaviour is observed
Static and dynamic verification
Static and dynamic V&V
Formal
specification
High-level
design
Requirements
specification
Detailed
design
Program
Prototype
Dynamic
validation
Static
verification
• Careful planning is required to get the most out
of testing and inspection processes
• Planning should start early in the development
process
• The plan should identify the balance between st
atic verification and testing
• Test planning is about defining standards for th
e testing process rather than describing product
tests
V & V planning
The V-model of development
Requirements
specification
System
specification
System
design
Detailed
design
Module and
unit code
and tess
Sub-system
integration
test plan
System
integration
test plan
Acceptance
test plan
Service
Acceptance
test
System
integration test
Sub-system
integration test
The structure of a software test plan
• The testing process
• Requirements traceability
• Tested items
• Testing schedule
• Test recording procedures
• Hardware and software requirements
• Constraints
Walkthroughs
• Informal examination of a product (document)
• Made up of:
– developers
– client
– next phase developers
– Software Quality Assurance group leader
• Produces:
– list of items not understood
– list of items thought to be incorrect
Software inspections
• Involve people examining the source represent
ation with the aim of discovering anomalies and
defects
• Do not require execution of a system so may be
used before implementation
• May be applied to any representation of the syst
em (requirements, design, test data, etc.)
• Very effective technique for discovering errors
Inspection success
• Many different defects may be discovered
in a single inspection. In testing, one defe
ct may mask another so several execution
s are required
• The reuse domain and programming kno
wledge so reviewers are likely to have se
en the types of error that commonly arise
Inspections and testing
• Inspections and testing are complementary and
not opposing verification techniques
• Both should be used during the V & V process
• Inspections can check conformance with a spec
ification but not conformance with the customer’
s real requirements
• Inspections cannot check non-functional charac
teristics such as performance, usability, etc.
Inspection pre-conditions
• A precise specification must be available
• Team members must be familiar with the
organisation standards
• Syntactically correct code must be available
• An error checklist should be prepared
• Management must accept that inspection will
increase costs early in the software process
• Management must not use inspections for st
aff
appraisal
Inspection procedure
• System overview presented to inspection team
• Code and associated documents are
distributed to inspection team in advance
• Inspection takes place and discovered errors
are noted
• Modifications are made to repair discovered
errors
• Re-inspection may or may not be required
Inspection teams
• Made up of at least 4 members
• Author of the code being inspected
• Inspector who finds errors, omissions and inco
nsistencies
• Reader who reads the code to the team
• Moderator who chairs the meeting and notes
discovered errors
• Other roles are Scribe and Chief moderator
Inspection checklists
• Checklist of common errors should be used to
drive the inspection
• Error checklist is programming language
dependent
• The 'weaker' the type checking, the larger the
checklist
• Examples: Initialization, Constant naming, loop
termination, array bounds, etc.
Inspection rate
• 500 statements/hour during overview
• 125 source statement/hour during individual
preparation
• 90-125 statements/hour can be inspected
• Inspection is therefore an expensive process
• Inspecting 500 lines costs about 40 man/hours
effort (@ $50/hr = $2000!!!)
• Can reveal the presence of errors NOT their ab
sence
• A successful test is a test which discovers one
or more errors
• The only validation technique for non-functional
requirements
• Should be used in conjunction with static
verification to provide full V&V coverage
Program testing
Execution based testing
• “Program testing can be a very effective way t
o show the presents of bugs but is hopelessly
inadequate for showing their absence” [Dijkst
ra]
• Fault: “bug” incorrect piece of code
• Failure: result of a fault
• Error: mistake made by the programmer/deve
loper
• Defect testing and debugging are distinct
processes
• Verification and validation is concerned with est
ablishing the existence of defects in a program
• Debugging is concerned with locating and
repairing these errors
• Debugging involves formulating a hypothesis
about program behaviour then testing these
hypotheses to find the system error
Testing and debugging
The debugging process
Locate
error
Design
error repair
Repair
error
Re-test
program
Test
results Specification Test
cases
Testing phases
Component
testing
Integration
testing
Software developer Independent testing team
Testing phases
• Component testing
– Testing of individual program components
– Usually the responsibility of the component deve
loper (except sometimes for critical systems)
– Tests are derived from the developer’s experien
ce
• Integration testing
– Testing of groups of components integrated to c
reate a system or sub-system
– The responsibility of an independent testing tea
m
– Tests are based on a system specification
• Only exhaustive testing can show a program
is free from defects. However, exhaustive tes
ting is impossible
• Tests should exercise a system's capabilities
rather than its components
• Testing old capabilities is more important tha
n testing new capabilities
• Testing typical situations is more important t
han boundary value cases
Testing priorities
• Test data Inputs which have been devise
d to test the system
• Test cases Inputs to test the system and
the predicted outputs from these inputs if
the system operates according to its speci
fication
Test data and test cases

More Related Content

Similar to SENG202-v-and-v-modeling_121810.pptx

UNIT 1.pptx
UNIT 1.pptxUNIT 1.pptx
UNIT 1.pptx
GNANAJESLINJ
 
Software Engineering (Testing Overview)
Software Engineering (Testing Overview)Software Engineering (Testing Overview)
Software Engineering (Testing Overview)
ShudipPal
 
Testing fundamentals
Testing fundamentalsTesting fundamentals
Testing fundamentals
Raviteja Chowdary Adusumalli
 
Lec25
Lec25Lec25
Software Engineering Lec 10 -software testing--
Software Engineering Lec 10 -software testing--Software Engineering Lec 10 -software testing--
Software Engineering Lec 10 -software testing--
Taymoor Nazmy
 
unit-2_20-july-2018 (1).pptx
unit-2_20-july-2018 (1).pptxunit-2_20-july-2018 (1).pptx
unit-2_20-july-2018 (1).pptx
PriyaFulpagare1
 
Softwarequalityassurance with Abu ul hassan Sahadvi
Softwarequalityassurance with Abu ul hassan SahadviSoftwarequalityassurance with Abu ul hassan Sahadvi
Softwarequalityassurance with Abu ul hassan Sahadvi
AbuulHassan2
 
Software quality assurance
Software quality assuranceSoftware quality assurance
Software quality assurance
Aman Adhikari
 
6. oose testing
6. oose testing6. oose testing
6. oose testing
Ashenafi Workie
 
Software testing strategies And its types
Software testing  strategies And its typesSoftware testing  strategies And its types
Software testing strategies And its types
MITULJAMANG
 
Sw testing
Sw testingSw testing
Unit iv-testing-pune-university-sres-coe
Unit iv-testing-pune-university-sres-coeUnit iv-testing-pune-university-sres-coe
Unit iv-testing-pune-university-sres-coe
Hitesh Mohapatra
 
Manual testing - Introduction to Manual Software testing
Manual testing - Introduction to Manual Software testingManual testing - Introduction to Manual Software testing
Manual testing - Introduction to Manual Software testing
Vibrant Technologies & Computers
 
Chapter 13 software testing strategies
Chapter 13 software testing strategiesChapter 13 software testing strategies
Chapter 13 software testing strategies
SHREEHARI WADAWADAGI
 
Software testing
Software testingSoftware testing
Software testing
Omar Al-Bokari
 
Objectorientedtesting 160320132146
Objectorientedtesting 160320132146Objectorientedtesting 160320132146
Objectorientedtesting 160320132146
vidhyyav
 
Object oriented testing
Object oriented testingObject oriented testing
Object oriented testing
Haris Jamil
 
Automated testing overview
Automated testing overviewAutomated testing overview
Automated testing overview
Alex Pop
 
Module V - Software Testing Strategies.pdf
Module V - Software Testing Strategies.pdfModule V - Software Testing Strategies.pdf
Module V - Software Testing Strategies.pdf
adhithanr
 
Fundamentals of software part 1
Fundamentals of software part 1Fundamentals of software part 1
Fundamentals of software part 1
Siddharth Sharma
 

Similar to SENG202-v-and-v-modeling_121810.pptx (20)

UNIT 1.pptx
UNIT 1.pptxUNIT 1.pptx
UNIT 1.pptx
 
Software Engineering (Testing Overview)
Software Engineering (Testing Overview)Software Engineering (Testing Overview)
Software Engineering (Testing Overview)
 
Testing fundamentals
Testing fundamentalsTesting fundamentals
Testing fundamentals
 
Lec25
Lec25Lec25
Lec25
 
Software Engineering Lec 10 -software testing--
Software Engineering Lec 10 -software testing--Software Engineering Lec 10 -software testing--
Software Engineering Lec 10 -software testing--
 
unit-2_20-july-2018 (1).pptx
unit-2_20-july-2018 (1).pptxunit-2_20-july-2018 (1).pptx
unit-2_20-july-2018 (1).pptx
 
Softwarequalityassurance with Abu ul hassan Sahadvi
Softwarequalityassurance with Abu ul hassan SahadviSoftwarequalityassurance with Abu ul hassan Sahadvi
Softwarequalityassurance with Abu ul hassan Sahadvi
 
Software quality assurance
Software quality assuranceSoftware quality assurance
Software quality assurance
 
6. oose testing
6. oose testing6. oose testing
6. oose testing
 
Software testing strategies And its types
Software testing  strategies And its typesSoftware testing  strategies And its types
Software testing strategies And its types
 
Sw testing
Sw testingSw testing
Sw testing
 
Unit iv-testing-pune-university-sres-coe
Unit iv-testing-pune-university-sres-coeUnit iv-testing-pune-university-sres-coe
Unit iv-testing-pune-university-sres-coe
 
Manual testing - Introduction to Manual Software testing
Manual testing - Introduction to Manual Software testingManual testing - Introduction to Manual Software testing
Manual testing - Introduction to Manual Software testing
 
Chapter 13 software testing strategies
Chapter 13 software testing strategiesChapter 13 software testing strategies
Chapter 13 software testing strategies
 
Software testing
Software testingSoftware testing
Software testing
 
Objectorientedtesting 160320132146
Objectorientedtesting 160320132146Objectorientedtesting 160320132146
Objectorientedtesting 160320132146
 
Object oriented testing
Object oriented testingObject oriented testing
Object oriented testing
 
Automated testing overview
Automated testing overviewAutomated testing overview
Automated testing overview
 
Module V - Software Testing Strategies.pdf
Module V - Software Testing Strategies.pdfModule V - Software Testing Strategies.pdf
Module V - Software Testing Strategies.pdf
 
Fundamentals of software part 1
Fundamentals of software part 1Fundamentals of software part 1
Fundamentals of software part 1
 

Recently uploaded

1 Million Orange Stickies later - Devoxx Poland 2024
1 Million Orange Stickies later - Devoxx Poland 20241 Million Orange Stickies later - Devoxx Poland 2024
1 Million Orange Stickies later - Devoxx Poland 2024
Alberto Brandolini
 
Stork Product Overview: An AI-Powered Autonomous Delivery Fleet
Stork Product Overview: An AI-Powered Autonomous Delivery FleetStork Product Overview: An AI-Powered Autonomous Delivery Fleet
Stork Product Overview: An AI-Powered Autonomous Delivery Fleet
Vince Scalabrino
 
Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...
Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...
Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...
sapnasaifi408
 
Secure-by-Design Using Hardware and Software Protection for FDA Compliance
Secure-by-Design Using Hardware and Software Protection for FDA ComplianceSecure-by-Design Using Hardware and Software Protection for FDA Compliance
Secure-by-Design Using Hardware and Software Protection for FDA Compliance
ICS
 
Introduction to Python and Basic Syntax.pptx
Introduction to Python and Basic Syntax.pptxIntroduction to Python and Basic Syntax.pptx
Introduction to Python and Basic Syntax.pptx
GevitaChinnaiah
 
Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...
Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...
Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...
simmi singh$A17
 
What’s new in VictoriaMetrics - Q2 2024 Update
What’s new in VictoriaMetrics - Q2 2024 UpdateWhat’s new in VictoriaMetrics - Q2 2024 Update
What’s new in VictoriaMetrics - Q2 2024 Update
VictoriaMetrics
 
Hands-on with Apache Druid: Installation & Data Ingestion Steps
Hands-on with Apache Druid: Installation & Data Ingestion StepsHands-on with Apache Druid: Installation & Data Ingestion Steps
Hands-on with Apache Druid: Installation & Data Ingestion Steps
servicesNitor
 
Ensuring Efficiency and Speed with Practical Solutions for Clinical Operations
Ensuring Efficiency and Speed with Practical Solutions for Clinical OperationsEnsuring Efficiency and Speed with Practical Solutions for Clinical Operations
Ensuring Efficiency and Speed with Practical Solutions for Clinical Operations
OnePlan Solutions
 
🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...
🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...
🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...
tinakumariji156
 
Enhancing non-Perl bioinformatic applications with Perl
Enhancing non-Perl bioinformatic applications with PerlEnhancing non-Perl bioinformatic applications with Perl
Enhancing non-Perl bioinformatic applications with Perl
Christos Argyropoulos
 
Call Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service Available
Call Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service AvailableCall Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service Available
Call Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service Available
sapnaanpad7
 
Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...
Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...
Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...
sapnasaifi408
 
Folding Cheat Sheet #5 - fifth in a series
Folding Cheat Sheet #5 - fifth in a seriesFolding Cheat Sheet #5 - fifth in a series
Folding Cheat Sheet #5 - fifth in a series
Philip Schwarz
 
Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...
Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...
Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...
anshsharma8761
 
Extreme DDD Modelling Patterns - 2024 Devoxx Poland
Extreme DDD Modelling Patterns - 2024 Devoxx PolandExtreme DDD Modelling Patterns - 2024 Devoxx Poland
Extreme DDD Modelling Patterns - 2024 Devoxx Poland
Alberto Brandolini
 
Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...
Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...
Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...
simmi singh$A17
 
Beginner's Guide to Observability@Devoxx PL 2024
Beginner's  Guide to Observability@Devoxx PL 2024Beginner's  Guide to Observability@Devoxx PL 2024
Beginner's Guide to Observability@Devoxx PL 2024
michniczscribd
 
Trailhead Talks_ Journey of an All-Star Ranger .pptx
Trailhead Talks_ Journey of an All-Star Ranger .pptxTrailhead Talks_ Journey of an All-Star Ranger .pptx
Trailhead Talks_ Journey of an All-Star Ranger .pptx
ImtiazBinMohiuddin
 

Recently uploaded (20)

1 Million Orange Stickies later - Devoxx Poland 2024
1 Million Orange Stickies later - Devoxx Poland 20241 Million Orange Stickies later - Devoxx Poland 2024
1 Million Orange Stickies later - Devoxx Poland 2024
 
Stork Product Overview: An AI-Powered Autonomous Delivery Fleet
Stork Product Overview: An AI-Powered Autonomous Delivery FleetStork Product Overview: An AI-Powered Autonomous Delivery Fleet
Stork Product Overview: An AI-Powered Autonomous Delivery Fleet
 
bgiolcb
bgiolcbbgiolcb
bgiolcb
 
Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...
Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...
Hi-Fi Call Girls In Hyderabad 💯Call Us 🔝 7426014248 🔝Independent Hyderabad Es...
 
Secure-by-Design Using Hardware and Software Protection for FDA Compliance
Secure-by-Design Using Hardware and Software Protection for FDA ComplianceSecure-by-Design Using Hardware and Software Protection for FDA Compliance
Secure-by-Design Using Hardware and Software Protection for FDA Compliance
 
Introduction to Python and Basic Syntax.pptx
Introduction to Python and Basic Syntax.pptxIntroduction to Python and Basic Syntax.pptx
Introduction to Python and Basic Syntax.pptx
 
Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...
Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...
Top Call Girls Lucknow ✔ 9352988975 ✔ Hi I Am Divya Vip Call Girl Services Pr...
 
What’s new in VictoriaMetrics - Q2 2024 Update
What’s new in VictoriaMetrics - Q2 2024 UpdateWhat’s new in VictoriaMetrics - Q2 2024 Update
What’s new in VictoriaMetrics - Q2 2024 Update
 
Hands-on with Apache Druid: Installation & Data Ingestion Steps
Hands-on with Apache Druid: Installation & Data Ingestion StepsHands-on with Apache Druid: Installation & Data Ingestion Steps
Hands-on with Apache Druid: Installation & Data Ingestion Steps
 
Ensuring Efficiency and Speed with Practical Solutions for Clinical Operations
Ensuring Efficiency and Speed with Practical Solutions for Clinical OperationsEnsuring Efficiency and Speed with Practical Solutions for Clinical Operations
Ensuring Efficiency and Speed with Practical Solutions for Clinical Operations
 
🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...
🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...
🔥 Kolkata Call Girls  👉 9079923931 👫 High Profile Call Girls Whatsapp Number ...
 
Enhancing non-Perl bioinformatic applications with Perl
Enhancing non-Perl bioinformatic applications with PerlEnhancing non-Perl bioinformatic applications with Perl
Enhancing non-Perl bioinformatic applications with Perl
 
Call Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service Available
Call Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service AvailableCall Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service Available
Call Girls Goa 💯Call Us 🔝 7426014248 🔝 Independent Goa Escorts Service Available
 
Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...
Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...
Independent Call Girls In Bangalore 💯Call Us 🔝 7426014248 🔝Independent Bangal...
 
Folding Cheat Sheet #5 - fifth in a series
Folding Cheat Sheet #5 - fifth in a seriesFolding Cheat Sheet #5 - fifth in a series
Folding Cheat Sheet #5 - fifth in a series
 
Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...
Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...
Call Girls Solapur ☎️ +91-7426014248 😍 Solapur Call Girl Beauty Girls Solapur...
 
Extreme DDD Modelling Patterns - 2024 Devoxx Poland
Extreme DDD Modelling Patterns - 2024 Devoxx PolandExtreme DDD Modelling Patterns - 2024 Devoxx Poland
Extreme DDD Modelling Patterns - 2024 Devoxx Poland
 
Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...
Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...
Independent Call Girls In Kolkata ✔ 7014168258 ✔ Hi I Am Divya Vip Call Girl ...
 
Beginner's Guide to Observability@Devoxx PL 2024
Beginner's  Guide to Observability@Devoxx PL 2024Beginner's  Guide to Observability@Devoxx PL 2024
Beginner's Guide to Observability@Devoxx PL 2024
 
Trailhead Talks_ Journey of an All-Star Ranger .pptx
Trailhead Talks_ Journey of an All-Star Ranger .pptxTrailhead Talks_ Journey of an All-Star Ranger .pptx
Trailhead Talks_ Journey of an All-Star Ranger .pptx
 

SENG202-v-and-v-modeling_121810.pptx

  • 2. V & V goals • Verification and validation should establish confidence that the software is fit for purpo se • This does NOT mean completely free of de fects • Rather, it must be good enough for its inten ded use and the type of use will determine the degree of confidence that is needed
  • 3. • Verification: The software should confor m to its specification (Are we building the product right?) • Validation: The software should do what t he user really requires (Are we building th e right product?) Verification vs. validation
  • 4. • Is a whole life-cycle process - V & V must be applied at each stage in the software p rocess. • Has two principal objectives – The discovery of defects in a system – The assessment of whether or not the syste m is usable in an operational situation. The V & V process
  • 5. • Software inspections and walkthroughs - Concerned with analysis of the static s ystem representation to discover proble ms (static verification) • Software testing - Concerned with exer cising and observing product behaviour (dynamic verification) – The system is executed with test data an d its operational behaviour is observed Static and dynamic verification
  • 6. Static and dynamic V&V Formal specification High-level design Requirements specification Detailed design Program Prototype Dynamic validation Static verification
  • 7. • Careful planning is required to get the most out of testing and inspection processes • Planning should start early in the development process • The plan should identify the balance between st atic verification and testing • Test planning is about defining standards for th e testing process rather than describing product tests V & V planning
  • 8. The V-model of development Requirements specification System specification System design Detailed design Module and unit code and tess Sub-system integration test plan System integration test plan Acceptance test plan Service Acceptance test System integration test Sub-system integration test
  • 9. The structure of a software test plan • The testing process • Requirements traceability • Tested items • Testing schedule • Test recording procedures • Hardware and software requirements • Constraints
  • 10. Walkthroughs • Informal examination of a product (document) • Made up of: – developers – client – next phase developers – Software Quality Assurance group leader • Produces: – list of items not understood – list of items thought to be incorrect
  • 11. Software inspections • Involve people examining the source represent ation with the aim of discovering anomalies and defects • Do not require execution of a system so may be used before implementation • May be applied to any representation of the syst em (requirements, design, test data, etc.) • Very effective technique for discovering errors
  • 12. Inspection success • Many different defects may be discovered in a single inspection. In testing, one defe ct may mask another so several execution s are required • The reuse domain and programming kno wledge so reviewers are likely to have se en the types of error that commonly arise
  • 13. Inspections and testing • Inspections and testing are complementary and not opposing verification techniques • Both should be used during the V & V process • Inspections can check conformance with a spec ification but not conformance with the customer’ s real requirements • Inspections cannot check non-functional charac teristics such as performance, usability, etc.
  • 14. Inspection pre-conditions • A precise specification must be available • Team members must be familiar with the organisation standards • Syntactically correct code must be available • An error checklist should be prepared • Management must accept that inspection will increase costs early in the software process • Management must not use inspections for st aff appraisal
  • 15. Inspection procedure • System overview presented to inspection team • Code and associated documents are distributed to inspection team in advance • Inspection takes place and discovered errors are noted • Modifications are made to repair discovered errors • Re-inspection may or may not be required
  • 16. Inspection teams • Made up of at least 4 members • Author of the code being inspected • Inspector who finds errors, omissions and inco nsistencies • Reader who reads the code to the team • Moderator who chairs the meeting and notes discovered errors • Other roles are Scribe and Chief moderator
  • 17. Inspection checklists • Checklist of common errors should be used to drive the inspection • Error checklist is programming language dependent • The 'weaker' the type checking, the larger the checklist • Examples: Initialization, Constant naming, loop termination, array bounds, etc.
  • 18. Inspection rate • 500 statements/hour during overview • 125 source statement/hour during individual preparation • 90-125 statements/hour can be inspected • Inspection is therefore an expensive process • Inspecting 500 lines costs about 40 man/hours effort (@ $50/hr = $2000!!!)
  • 19. • Can reveal the presence of errors NOT their ab sence • A successful test is a test which discovers one or more errors • The only validation technique for non-functional requirements • Should be used in conjunction with static verification to provide full V&V coverage Program testing
  • 20. Execution based testing • “Program testing can be a very effective way t o show the presents of bugs but is hopelessly inadequate for showing their absence” [Dijkst ra] • Fault: “bug” incorrect piece of code • Failure: result of a fault • Error: mistake made by the programmer/deve loper
  • 21. • Defect testing and debugging are distinct processes • Verification and validation is concerned with est ablishing the existence of defects in a program • Debugging is concerned with locating and repairing these errors • Debugging involves formulating a hypothesis about program behaviour then testing these hypotheses to find the system error Testing and debugging
  • 22. The debugging process Locate error Design error repair Repair error Re-test program Test results Specification Test cases
  • 24. Testing phases • Component testing – Testing of individual program components – Usually the responsibility of the component deve loper (except sometimes for critical systems) – Tests are derived from the developer’s experien ce • Integration testing – Testing of groups of components integrated to c reate a system or sub-system – The responsibility of an independent testing tea m – Tests are based on a system specification
  • 25. • Only exhaustive testing can show a program is free from defects. However, exhaustive tes ting is impossible • Tests should exercise a system's capabilities rather than its components • Testing old capabilities is more important tha n testing new capabilities • Testing typical situations is more important t han boundary value cases Testing priorities
  • 26. • Test data Inputs which have been devise d to test the system • Test cases Inputs to test the system and the predicted outputs from these inputs if the system operates according to its speci fication Test data and test cases
  翻译: