Содержание
- 2. Agenda Introduction Technique Examples Applicability and Limitations Summary Practice References
- 4. Introduction What is equivalence class testing? What is it used for? Equivalence class testing is a
- 5. Introduction: Situation We are writing a module for a human resources system that decides how we
- 6. Introduction: Coverage Should we test the module for the following ages: 0, 1, 2, 3, 4,
- 7. Introduction: Solution 1 If (applicantAge == 0) hireStatus="NO"; If (applicantAge == 1) hireStatus="NO"; … If (applicantAge
- 8. Introduction: Let’s believe
- 9. Introduction: Solution 2 If (applicantAge >= 0 && applicantAge hireStatus="NO"; If (applicantAge >= 16 && applicantAge
- 10. Introduction: Benefits Using the equivalence class approach, we have reduced the number of test cases From
- 11. Introduction: Definition An equivalence class consists of a set of data that is treated the same
- 12. Introduction: Assumptions Specifically, we would expect that: If one test case in an equivalence class detects
- 13. Introduction: Solution 3 If (applicantAge >= 0 && applicantAge hireStatus="NO"; If (applicantAge >= 16 && applicantAge
- 14. Introduction: Ready? Now, are we ready to begin testing? Probably not. What about input values like
- 15. Technique
- 16. Technique: Steps 1. Identify the equivalence classes. 2. Create a test case for each equivalence class.
- 17. Technique: Continuous Continuous equivalence classes For a valid input we might choose $1,342/month. For invalids we
- 18. Technique: Discrete Discrete equivalence classes For a valid input we might choose 2 houses. Invalids could
- 19. Technique: Array Single selection equivalence classes For a valid input we must use "person." For an
- 20. Technique: Array Multiple selection equivalence class While the rule says choose one test case from the
- 21. Technique: Contradictions But, if this were a list of the fifty states, and the various territories
- 22. Technique: Combination Rarely we will have the time to create individual tests for every separate equivalence
- 23. Technique: All invalid A test case of invalid data values. If the system accepts this input
- 24. Technique: One invalid In many cases, errors in one input field may cancel out or mask
- 25. Technique: Varying values For additional warm and fuzzy feelings, the inputs (both valid and invalid) could
- 26. Technique: Tips Another approach to using equivalence classes is to examine the outputs rather than the
- 27. Examples
- 28. Examples: 1 No invalid choices. It reduces the number of test cases the tester must create.
- 29. Examples: 2 Input to this field can be between one and four numeric characters (0, 1,
- 30. Examples: 3 The valid symbols are {A, AA, AABC, AAC, ..., ZOLT, ZOMX, ZONA, ZRAN}. The
- 31. Examples: 4 Rarely will we create separate sets of test cases for each input. Generally it
- 32. Applicability and Limitations
- 33. Applicability and Limitations Equivalence class testing can significantly reduce the number of test cases that must
- 34. Applicability and Limitations Very often your designers and programmers use GUI design tools that can enforce
- 35. Summary
- 36. Summary Equivalence class testing is a technique used to reduce the number of test cases to
- 37. Practice
- 38. Practice ZIP Code – five numeric digits. Last Name – one through fifteen characters (including alphabetic
- 39. Practice: Answers 1 ZIP Code – five numeric digits. Length Valid: 5 Invalid: 3; 20 Characters
- 40. Practice: Answers 2 Last Name – one through fifteen characters (including alphabetic characters, periods, hyphens, apostrophes,
- 41. Practice: Answers 3 User ID – eight characters at least two of which are not alphabetic
- 42. Practice: Answers 4 Student ID – eight characters. The first two represent the student's home campus
- 43. Practice: Answers 5
- 44. References
- 47. Скачать презентацию