Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 1: Boundary Value Testing

Similar presentations


Presentation on theme: "Chapter 1: Boundary Value Testing"— Presentation transcript:

1 Chapter 1: Boundary Value Testing
Unit III Chapter 1: Boundary Value Testing

2 Boundary Value Testing
Boundary value analysis is a type of black box or specification based testing technique in which tests are performed using the boundary values. Practically, due to time and budget considerations, it is not possible to perform exhausting testing for each set of test data, especially when there is a large pool of input combinations. We use two techniques - Equivalence Partitioning & Boundary Value Analysis testing techniques to achieve this.

3 Boundary testing is the process of testing between extreme ends or boundaries between partitions of the input values. So these extreme ends like Start- End, Lower- Upper, Maximum-Minimum, Just Inside-Just Outside values are called boundary values and the testing is called "boundary testing". The basic idea in boundary value testing is to select input variable values at their: Minimum Just above the minimum A nominal value Just below the maximum Maximum

4

5 Example An exam has a pass boundary at 50 percent, merit at 75 percent and distinction at 85 percent. The Valid Boundary values for this scenario will be as follows: 49, 50 - for pass 74, 75 - for merit 84, 85 - for distinction Boundary values are validated against both the valid boundaries and invalid boundaries. The Invalid Boundary Cases for the above example can be given as follows: 0 - for lower limit boundary value 101 - for upper limit boundary value

6 Example on Boundary Value Analysis Test Case Design Technique:
Assume, we have to test a field which accepts Age 18 – 56

7 Minimum boundary value is 18
Maximum boundary value is 56 Valid Inputs: 18,19,55,56 Invalid Inputs: 17 and 57 Test case 1: Enter the value 17 (18-1) = Invalid Test case 2: Enter the value 18 = Valid Test case 3: Enter the value 19 (18+1) = Valid Test case 4: Enter the value 55 (56-1) = Valid Test case 5: Enter the value 56 = Valid Test case 6: Enter the value 57 (56+1) =Invalid

8 Example 2: Assume we have to test a text field (Name) which accepts the length between 6-12 characters.

9 Minimum boundary value is 6
Maximum boundary value is 12 Valid text length is 6, 7, 11, 12 Invalid text length is 5, 13 Test case 1: Text length of 5 (min-1) = Invalid Test case 2: Text length of exactly 6 (min) = Valid Test case 3: Text length of 7 (min+1) = Valid Test case 4: Text length of 11 (max-1) = Valid Test case 5: Text length of exactly 12 (max) = Valid Test case 6: Text length of 13 (max+1) = Invalid

10 Normal Boundary Value Testing
In the general application of Boundary Value Analysis can be done in a uniform manner. The basic form of implementation is to maintain all but one of the variables at their nominal (normal or average) values and allowing the remaining variable to take on its extreme values. The values used to test the extremities are: Min Minimal Min Just above Minimal Nom Average Max Just below Maximum Max Maximum

11

12 NextDate Function NEXTDATE is a function of three variables: month, day, and year, for years from 1812 to It returns the date of the next day. NEXTDATE( Dec, 31, 1991) returns Jan NEXTDATE( Feb, 21, 1991) returns Feb NEXTDATE( Feb, 28, 1991) returns Mar NEXTDATE( Feb, 28, 1992) returns Feb

13 Boundary Value Test Cases for NextDate
Month Day Year Expected Output 1 1812 1, 2, 1812 2 1813 1, 2, 1813 3 1912 1, 2, 1912 4 2011 1, 2, 2011 5 2012 1, 2, 2012 6 1, 3, 1812 7 1, 3, 1813 8 1, 3, 1912 9 1, 3, 2011 10 1, 3, 2012 11 15 1, 16, 1812 12 1, 16, 1813 13 1, 16, 1912 14 1, 16, 2011 1, 16, 2012

14 Special Value Test Cases
Month Day Year Reason SV-1 2 28 2012 Feb. 28 in a leap year SV-2 2013 Feb. 28 in a common year SV-3 29 Leap day in a leap year SV-4 2000 Leap day in 2000 SV-5 1900 Feb. 28 in 1900 SV-6 12 31 2011 End of year SV-7 10 End of 31-day month SV-8 11 30 End of 30-day month SV-9 Last day of defined interval

15 Robustness Testing In BVA, we remain within the legitimate boundary of our range i.e. for testing we consider values like (min, min+, nom, max-, max) whereas in Robustness testing, we try to cross these legitimate boundaries as well. Thus for testing here we consider the values like (min-, min, min+, nom, max-, max, max+)

16

17 Hierarchy Boundary Value testing of n inputs : 4n + 1
Robustness testing of n inputs : 6n + 1 “Worst case” for boundary value : 5n “Worst case” for robustness : 7n 1) Boundary Value is a subset of Robustness 2) Worst Case of boundary value is a subset of Worst Case of robustness

18 Worst case BVT

19

20 Test cases

21

22 Special Value Testing The testing executed by Special Value Testing technique is based on past experiences, which validates that no bugs or defects are left undetected. Moreover, the testers are extremely knowledgeable about the industry and use this information while performing Special Value testing. Another benefit of opting Special Value Testing technique is that it is Ad-hoc in nature. There are no guidelines used by the testers other than their “best engineering judgment”. The most important aspect of this testing is that, it has had some very valuable inputs and success in finding bugs and errors while testing a software.

23 Random Testing Random Testing is a form of functional black box testing that is performed when there is not enough time to write and execute the tests.

24 Random Testing Characteristics
Random testing is performed where the defects are NOT identified in regular intervals. Random input is used to test the system's reliability and performance. Saves time and effort than actual test efforts. Other Testing methods Cannot be used to.

25


Download ppt "Chapter 1: Boundary Value Testing"

Similar presentations


Ads by Google