SlideShare una empresa de Scribd logo
1 de 31
Chapter  13 & 14 Software Testing Strategies and Techniques   Software Engineering: A Practitioner’s Approach, 6th edition by Roger S. Pressman
Software Testing Testing is the process of exercising a program with the specific intent of finding errors prior to delivery to the end user.
What Testing Shows errors requirements conformance performance an indication of quality
Who Tests the Software? developer independent tester Understands the system  but, will test "gently" and, is driven by "delivery" Must learn about the system, but, will attempt to break it and, is driven by quality
Validation vs Verification ,[object Object],[object Object],[object Object],[object Object]
Testing Strategy unit test integration test validation test system test
Testing Strategy ,[object Object],[object Object],[object Object],[object Object],[object Object]
Unit Testing module to be tested test cases results software engineer
Unit Testing interface  local data structures boundary conditions independent paths error handling paths module to be tested test cases
Unit Test Environment Module stub stub driver RESULTS interface  local data structures boundary conditions independent paths error handling paths test cases
Integration Testing Strategies ,[object Object],[object Object],[object Object]
Top Down Integration top module is tested with  stubs stubs are replaced one at  a time, "depth first" as new modules are integrated,  some subset of tests is re-run A B C D E F G
Bottom-Up Integration drivers are replaced one at a  time, "depth first" worker modules are grouped into  builds and integrated A B C D E F G cluster
Regression Testing ,[object Object],[object Object]
High Order Testing ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
What is a “Good” Test? ,[object Object]
Test Case Design "Bugs lurk in corners  and congregate at  boundaries ..." Boris Beizer OBJECTIVE CRITERIA CONSTRAINT to uncover errors in a complete manner with a minimum of effort and time
Exhaustive Testing loop < 20 X There are 10  possible paths! If we execute one test per millisecond, it would take 3,170 years to test this program!! 14
Selective Testing loop < 20 X Selected path
Software Testing Methods Strategies white-box methods   black-box methods
White-Box Testing ... our goal is to ensure that all  statements and conditions have  been executed at least once ...
Why Cover? logic errors and incorrect assumptions  are inversely proportional to a path's  execution probability we often  believe that a path is not  likely to be executed;  in fact, reality is  often counter intuitive typographical errors are random;  it's  likely that untested paths will contain  some
Basis Path Testing First, we compute the cyclomatic  complexity: number of simple decisions + 1  or number of enclosed areas + 1 In this case, V(G) = 4
Cyclomatic Complexity A number of industry studies have indicated  that the higher V(G), the higher the probability  or errors. V(G) modules modules in this range are  more error prone
Basis Path Testing Next, we derive the  independent paths: Since V(G) = 4, there are four paths Path 1:  1,2,3,6,7,8 Path 2:  1,2,3,5,7,8 Path 3:  1,2,4,7,8 Path 4:  1,2,4,7,2,4,...7,8 Finally, we derive test cases to exercise these  paths. 1 2 3 4 5 6 7 8
Basis Path Testing Notes you don't need a flow chart,  but the picture will help when  you trace program paths count each simple logical test,  compound tests count as 2 or  more basis path testing should be  applied to critical modules
Black-Box Testing requirements events input output
Equivalence Partitioning user queries mouse picks output formats prompts FK input data
Sample Equivalence Classes user supplied commands responses to system prompts file names computational data physical parameters  bounding values initiation values output data formatting responses to error messages graphical data (e.g., mouse picks) data outside bounds of the program  physically impossible data proper value supplied in wrong place Valid data Invalid data
Boundary Value Analysis user queries mouse picks output formats prompts FK input data output domain input domain
OOT Methods: Behavior Testing The tests to be designed should achieve all state coverage [KIR94]. That is, the operation sequences should cause the Account class to make transition through all allowable states

Más contenido relacionado

La actualidad más candente

SE_Lec 09_ UML Behaviour Diagrams
SE_Lec 09_ UML Behaviour DiagramsSE_Lec 09_ UML Behaviour Diagrams
SE_Lec 09_ UML Behaviour DiagramsAmr E. Mohamed
 
Characteristics of Software
Characteristics of SoftwareCharacteristics of Software
Characteristics of SoftwareUpekha Vandebona
 
Pressman ch-22-process-and-project-metrics
Pressman ch-22-process-and-project-metricsPressman ch-22-process-and-project-metrics
Pressman ch-22-process-and-project-metricsSeema Kamble
 
Software reliability
Software reliabilitySoftware reliability
Software reliabilityAnand Kumar
 
Unit 5- Architectural Design in software engineering
Unit 5- Architectural Design in software engineering Unit 5- Architectural Design in software engineering
Unit 5- Architectural Design in software engineering arvind pandey
 
Black Box Testing
Black Box TestingBlack Box Testing
Black Box TestingTestbytes
 
System Models in Software Engineering SE7
System Models in Software Engineering SE7System Models in Software Engineering SE7
System Models in Software Engineering SE7koolkampus
 
Software Metrics - Software Engineering
Software Metrics - Software EngineeringSoftware Metrics - Software Engineering
Software Metrics - Software EngineeringDrishti Bhalla
 
States, state graphs and transition testing
States, state graphs and transition testingStates, state graphs and transition testing
States, state graphs and transition testingABHISHEK KUMAR
 
IT8076 - SOFTWARE TESTING
IT8076 - SOFTWARE TESTINGIT8076 - SOFTWARE TESTING
IT8076 - SOFTWARE TESTINGSathya R
 
Lect2 conventional software management
Lect2 conventional software managementLect2 conventional software management
Lect2 conventional software managementmeena466141
 
Integration testing
Integration testingIntegration testing
Integration testingqueen jemila
 
Chapter 15 software product metrics
Chapter 15 software product metricsChapter 15 software product metrics
Chapter 15 software product metricsSHREEHARI WADAWADAGI
 
Software maintenance
Software maintenance Software maintenance
Software maintenance Rajeev Sharan
 
Software architecture design ppt
Software architecture design pptSoftware architecture design ppt
Software architecture design pptfarazimlak
 
Control Flow Testing
Control Flow TestingControl Flow Testing
Control Flow TestingHirra Sultan
 
Architecture Description Languages: An Overview
Architecture Description Languages: An OverviewArchitecture Description Languages: An Overview
Architecture Description Languages: An Overviewelliando dias
 
Software maintenance and configuration management, software engineering
Software maintenance and  configuration management, software engineeringSoftware maintenance and  configuration management, software engineering
Software maintenance and configuration management, software engineeringRupesh Vaishnav
 

La actualidad más candente (20)

SE_Lec 09_ UML Behaviour Diagrams
SE_Lec 09_ UML Behaviour DiagramsSE_Lec 09_ UML Behaviour Diagrams
SE_Lec 09_ UML Behaviour Diagrams
 
Characteristics of Software
Characteristics of SoftwareCharacteristics of Software
Characteristics of Software
 
Pressman ch-22-process-and-project-metrics
Pressman ch-22-process-and-project-metricsPressman ch-22-process-and-project-metrics
Pressman ch-22-process-and-project-metrics
 
Software reliability
Software reliabilitySoftware reliability
Software reliability
 
Unit 5- Architectural Design in software engineering
Unit 5- Architectural Design in software engineering Unit 5- Architectural Design in software engineering
Unit 5- Architectural Design in software engineering
 
Black Box Testing
Black Box TestingBlack Box Testing
Black Box Testing
 
System Models in Software Engineering SE7
System Models in Software Engineering SE7System Models in Software Engineering SE7
System Models in Software Engineering SE7
 
Software Metrics - Software Engineering
Software Metrics - Software EngineeringSoftware Metrics - Software Engineering
Software Metrics - Software Engineering
 
States, state graphs and transition testing
States, state graphs and transition testingStates, state graphs and transition testing
States, state graphs and transition testing
 
IT8076 - SOFTWARE TESTING
IT8076 - SOFTWARE TESTINGIT8076 - SOFTWARE TESTING
IT8076 - SOFTWARE TESTING
 
Lect2 conventional software management
Lect2 conventional software managementLect2 conventional software management
Lect2 conventional software management
 
Integration testing
Integration testingIntegration testing
Integration testing
 
The Art of Debugging.pptx
The Art of Debugging.pptxThe Art of Debugging.pptx
The Art of Debugging.pptx
 
Chapter 15 software product metrics
Chapter 15 software product metricsChapter 15 software product metrics
Chapter 15 software product metrics
 
Software maintenance
Software maintenance Software maintenance
Software maintenance
 
Black box and white box testing
Black box and white box testingBlack box and white box testing
Black box and white box testing
 
Software architecture design ppt
Software architecture design pptSoftware architecture design ppt
Software architecture design ppt
 
Control Flow Testing
Control Flow TestingControl Flow Testing
Control Flow Testing
 
Architecture Description Languages: An Overview
Architecture Description Languages: An OverviewArchitecture Description Languages: An Overview
Architecture Description Languages: An Overview
 
Software maintenance and configuration management, software engineering
Software maintenance and  configuration management, software engineeringSoftware maintenance and  configuration management, software engineering
Software maintenance and configuration management, software engineering
 

Similar a Slides chapters 13-14

Software testing
Software testingSoftware testing
Software testingBala Ganesh
 
Software testing mtech project in jalandhar
Software testing mtech project in jalandharSoftware testing mtech project in jalandhar
Software testing mtech project in jalandhardeepikakaler1
 
Software testing mtech project in ludhiana
Software testing mtech project in ludhianaSoftware testing mtech project in ludhiana
Software testing mtech project in ludhianadeepikakaler1
 
lec-11 Testing.ppt
lec-11 Testing.pptlec-11 Testing.ppt
lec-11 Testing.pptdebjani12
 
6 weeks summer training in software testing,ludhiana
6 weeks summer training in software testing,ludhiana6 weeks summer training in software testing,ludhiana
6 weeks summer training in software testing,ludhianadeepikakaler1
 
6 weeks summer training in software testing,jalandhar
6 weeks summer training in software testing,jalandhar6 weeks summer training in software testing,jalandhar
6 weeks summer training in software testing,jalandhardeepikakaler1
 
6months industrial training in software testing, ludhiana
6months industrial training in software testing, ludhiana6months industrial training in software testing, ludhiana
6months industrial training in software testing, ludhianadeepikakaler1
 
6months industrial training in software testing, jalandhar
6months industrial training in software testing, jalandhar6months industrial training in software testing, jalandhar
6months industrial training in software testing, jalandhardeepikakaler1
 
Testing Software Solutions
Testing Software SolutionsTesting Software Solutions
Testing Software Solutionsgavhays
 
Software Testing Tecniques
Software Testing TecniquesSoftware Testing Tecniques
Software Testing Tecniquesersanbilik
 
4. The Software Development Process - Testing
4. The Software Development Process - Testing4. The Software Development Process - Testing
4. The Software Development Process - TestingForrester High School
 
5.Black Box Testing and Levels of Testing.ppt
5.Black Box Testing and Levels of Testing.ppt5.Black Box Testing and Levels of Testing.ppt
5.Black Box Testing and Levels of Testing.pptSyedAhmad732853
 
Lecture (Software Testing).pptx
Lecture (Software Testing).pptxLecture (Software Testing).pptx
Lecture (Software Testing).pptxskknowledge
 

Similar a Slides chapters 13-14 (20)

Software testing
Software testingSoftware testing
Software testing
 
Software testing
Software testingSoftware testing
Software testing
 
testing
testingtesting
testing
 
Software testing (2)
Software testing (2)Software testing (2)
Software testing (2)
 
Software testing mtech project in jalandhar
Software testing mtech project in jalandharSoftware testing mtech project in jalandhar
Software testing mtech project in jalandhar
 
Software testing mtech project in ludhiana
Software testing mtech project in ludhianaSoftware testing mtech project in ludhiana
Software testing mtech project in ludhiana
 
Software testing methods
Software testing methodsSoftware testing methods
Software testing methods
 
Testing
TestingTesting
Testing
 
lec-11 Testing.ppt
lec-11 Testing.pptlec-11 Testing.ppt
lec-11 Testing.ppt
 
6 weeks summer training in software testing,ludhiana
6 weeks summer training in software testing,ludhiana6 weeks summer training in software testing,ludhiana
6 weeks summer training in software testing,ludhiana
 
6 weeks summer training in software testing,jalandhar
6 weeks summer training in software testing,jalandhar6 weeks summer training in software testing,jalandhar
6 weeks summer training in software testing,jalandhar
 
6months industrial training in software testing, ludhiana
6months industrial training in software testing, ludhiana6months industrial training in software testing, ludhiana
6months industrial training in software testing, ludhiana
 
6months industrial training in software testing, jalandhar
6months industrial training in software testing, jalandhar6months industrial training in software testing, jalandhar
6months industrial training in software testing, jalandhar
 
Testing Software Solutions
Testing Software SolutionsTesting Software Solutions
Testing Software Solutions
 
Testing
TestingTesting
Testing
 
Software Testing Tecniques
Software Testing TecniquesSoftware Testing Tecniques
Software Testing Tecniques
 
Blackbox
BlackboxBlackbox
Blackbox
 
4. The Software Development Process - Testing
4. The Software Development Process - Testing4. The Software Development Process - Testing
4. The Software Development Process - Testing
 
5.Black Box Testing and Levels of Testing.ppt
5.Black Box Testing and Levels of Testing.ppt5.Black Box Testing and Levels of Testing.ppt
5.Black Box Testing and Levels of Testing.ppt
 
Lecture (Software Testing).pptx
Lecture (Software Testing).pptxLecture (Software Testing).pptx
Lecture (Software Testing).pptx
 

Más de Priyanka Shetty (19)

Slides chapters 24-25
Slides chapters 24-25Slides chapters 24-25
Slides chapters 24-25
 
Slides chapters 21-23
Slides chapters 21-23Slides chapters 21-23
Slides chapters 21-23
 
Slides chapters 6-7
Slides chapters 6-7Slides chapters 6-7
Slides chapters 6-7
 
Slides chapter 19
Slides chapter 19Slides chapter 19
Slides chapter 19
 
Slides chapter 17
Slides chapter 17Slides chapter 17
Slides chapter 17
 
Slides chapter 16
Slides chapter 16Slides chapter 16
Slides chapter 16
 
Slides chapter 15
Slides chapter 15Slides chapter 15
Slides chapter 15
 
Slides chapter 12
Slides chapter 12Slides chapter 12
Slides chapter 12
 
Slides chapter 11
Slides chapter 11Slides chapter 11
Slides chapter 11
 
Slides chapter 10
Slides chapter 10Slides chapter 10
Slides chapter 10
 
Slides chapter 9
Slides chapter 9Slides chapter 9
Slides chapter 9
 
Slides chapter 8
Slides chapter 8Slides chapter 8
Slides chapter 8
 
Slides chapter 5
Slides chapter 5Slides chapter 5
Slides chapter 5
 
Slides chapter 3
Slides chapter 3Slides chapter 3
Slides chapter 3
 
Slides chapter 2
Slides chapter 2Slides chapter 2
Slides chapter 2
 
Slides chapter 1
Slides chapter 1Slides chapter 1
Slides chapter 1
 
Slides chapters 28-32
Slides chapters 28-32Slides chapters 28-32
Slides chapters 28-32
 
Slides chapters 26-27
Slides chapters 26-27Slides chapters 26-27
Slides chapters 26-27
 
Personal Hygiene
Personal HygienePersonal Hygiene
Personal Hygiene
 

Slides chapters 13-14

  • 1. Chapter 13 & 14 Software Testing Strategies and Techniques Software Engineering: A Practitioner’s Approach, 6th edition by Roger S. Pressman
  • 2. Software Testing Testing is the process of exercising a program with the specific intent of finding errors prior to delivery to the end user.
  • 3. What Testing Shows errors requirements conformance performance an indication of quality
  • 4. Who Tests the Software? developer independent tester Understands the system but, will test &quot;gently&quot; and, is driven by &quot;delivery&quot; Must learn about the system, but, will attempt to break it and, is driven by quality
  • 5.
  • 6. Testing Strategy unit test integration test validation test system test
  • 7.
  • 8. Unit Testing module to be tested test cases results software engineer
  • 9. Unit Testing interface local data structures boundary conditions independent paths error handling paths module to be tested test cases
  • 10. Unit Test Environment Module stub stub driver RESULTS interface local data structures boundary conditions independent paths error handling paths test cases
  • 11.
  • 12. Top Down Integration top module is tested with stubs stubs are replaced one at a time, &quot;depth first&quot; as new modules are integrated, some subset of tests is re-run A B C D E F G
  • 13. Bottom-Up Integration drivers are replaced one at a time, &quot;depth first&quot; worker modules are grouped into builds and integrated A B C D E F G cluster
  • 14.
  • 15.
  • 16.
  • 17. Test Case Design &quot;Bugs lurk in corners and congregate at boundaries ...&quot; Boris Beizer OBJECTIVE CRITERIA CONSTRAINT to uncover errors in a complete manner with a minimum of effort and time
  • 18. Exhaustive Testing loop < 20 X There are 10 possible paths! If we execute one test per millisecond, it would take 3,170 years to test this program!! 14
  • 19. Selective Testing loop < 20 X Selected path
  • 20. Software Testing Methods Strategies white-box methods black-box methods
  • 21. White-Box Testing ... our goal is to ensure that all statements and conditions have been executed at least once ...
  • 22. Why Cover? logic errors and incorrect assumptions are inversely proportional to a path's execution probability we often believe that a path is not likely to be executed; in fact, reality is often counter intuitive typographical errors are random; it's likely that untested paths will contain some
  • 23. Basis Path Testing First, we compute the cyclomatic complexity: number of simple decisions + 1 or number of enclosed areas + 1 In this case, V(G) = 4
  • 24. Cyclomatic Complexity A number of industry studies have indicated that the higher V(G), the higher the probability or errors. V(G) modules modules in this range are more error prone
  • 25. Basis Path Testing Next, we derive the independent paths: Since V(G) = 4, there are four paths Path 1: 1,2,3,6,7,8 Path 2: 1,2,3,5,7,8 Path 3: 1,2,4,7,8 Path 4: 1,2,4,7,2,4,...7,8 Finally, we derive test cases to exercise these paths. 1 2 3 4 5 6 7 8
  • 26. Basis Path Testing Notes you don't need a flow chart, but the picture will help when you trace program paths count each simple logical test, compound tests count as 2 or more basis path testing should be applied to critical modules
  • 27. Black-Box Testing requirements events input output
  • 28. Equivalence Partitioning user queries mouse picks output formats prompts FK input data
  • 29. Sample Equivalence Classes user supplied commands responses to system prompts file names computational data physical parameters bounding values initiation values output data formatting responses to error messages graphical data (e.g., mouse picks) data outside bounds of the program physically impossible data proper value supplied in wrong place Valid data Invalid data
  • 30. Boundary Value Analysis user queries mouse picks output formats prompts FK input data output domain input domain
  • 31. OOT Methods: Behavior Testing The tests to be designed should achieve all state coverage [KIR94]. That is, the operation sequences should cause the Account class to make transition through all allowable states