Equivalence Class partitioning & Boundary value analysis

Equivalence partitioning together with Boundary value analysis both the techniques aid us to abide by seek information effectively which volition almost encompass all the seek scenarios together with its all aid us inwards alternative of seek cases.

As nosotros all know testing for all possible status is non possible, if soul campaign to seek software for all the possible status therefore it mightiness convey to a greater extent than than 2-3 twelvemonth or fifty-fifty to a greater extent than than that.

Take a example, suppose at that spot is an e-commerce site nether seek together with you lot are the Tester together with 1 of the requirement of e-commerce site is ”user should instruct 5% discount on purchasing goods worth rupee 5,000 to 10,000 together with if user buy to a greater extent than than 10,001 therefore it should instruct 7% discount”.

After agreement the requirements testers involve to write seek cases. It is possible to banking concern fit the discount for each sum ?? holler upwards on it. Would you lot write the seek cases every bit follow ??

Under next status user should non instruct whatever discount
--> banking concern fit the discount when user buy a goods of 1 rupee.
--> banking concern fit the discount when user buy a goods of ii rupee.
.
.
.up to 
--> banking concern fit the discount when user buy a goods of 4999 rupee.


Under next status user should instruct 5% discount
--> banking concern fit the discount when user buy a goods of 5001 rupee.
--> banking concern fit the discount when user buy a goods of 5002 rupee.
.
.up to 9999
--> banking concern fit the discount when user buy a goods of 10,000 rupee.

Under next status user should instruct 7% discount
--> banking concern fit the discount when user buy a goods of 10,001 rupee.
--> banking concern fit the discount when user buy a goods of 10,002 rupee.
.
.up to infinity
--> banking concern fit the discount when user buy a goods of infinity rupee.

Now holler upwards on it, to simply banking concern fit the no discount status agency when user buy a goods less than 5000 rupee therefore organization should non give discount to her. To evaluate this for each together with every status tester involve to write 5000 seek cases. For the minute status agency when user buy a goods inwards betwixt 5001 to 10,000 rupees, this requires 4999 seek cases. And at 1 time end status when user buy a goods worth rupee to a greater extent than than 10,000 therefore at that spot are interplanetary space seek cases involve to locomote written.So this is possible to write such a huge set out of seek cases together with execute them ??? Definitely a Big NO.

To overcome this problem. These techniques are developed. boundary value analysis together with equivalence shape partitioning are aid us a lot. Using those techniques set out of seek cases tin give the axe locomote reduced to few seek cases without compromising the character of testing. It tin give the axe locomote useful inwards whatever testing phase, similar it is useful inwards unit, integration , organization etc. Means non restriction to utilisation at item phase.Both the testing techniques are Black Box Testing Techniques together with Without knowing the code construction nosotros tin give the axe utilisation these testing techniques. Let speak over first, Equivalence shape partitioning. How does it aid us for alternative seek cases.

Equivalence Class Partitioning :
Equivalence shape partitioning, hither nosotros exercise a equivalence purpose agency inwards unproblematic give-and-take nosotros exercise a equivalence partitions(groups). To empathise this lets convey a higher upwards given instance together with how exercise nosotros brand a purpose or grouping of it. 
Equivalence Class Partitioning
First empathise the image. We conduct keep created 3 equivalence partitions,

First purpose is 0 to 4,999, minute purpose is 4,999 to 10,000 together with the 3rd purpose together with end 1 is from 10,000 to infinity.

Here nosotros made an equivalence sectionalization every bit per the status given. Means logically if nosotros buy a adept betwixt 0 to 4,999 organization should non give us whatever discount together with inwards betwixt 5,000 to 10,000 organization should give us five % discount together with higher upwards that nosotros would instruct vii % discount. Based on this scenario nosotros made a equivalence part/group As you lot tin give the axe run across inwards higher upwards image.

So using this techniques nosotros volition pick out 1 value from each sectionalization / part. So from commencement grouping nosotros conduct keep selected value 2,999, from minute grouping nosotros conduct keep selected value 6,500 together with from end grouping nosotros conduct keep selected an values 11,200 together with 22,888.

So afterward using Equivalence shape partitioning, nosotros conduct keep derived next seek cases.

--> banking concern fit the discount when user buy a goods of 2,999.
Expected Result : user should non instruct whatever discount.

--> banking concern fit the discount when user buy a goods of 6,500.
Expected Result : user should instruct 5% discount.

--> banking concern fit the discount when user buy a goods of 11,200.
Expected Result : user should instruct 7% discount.

--> banking concern fit the discount when user buy a goods of 22,888.
Expected Result : user should instruct 7% discount.

See simply a four seek cases past times using equivalence shape partitioning. Test instance numbers are dramatically decreased to simply four together with nosotros volition derive few to a greater extent than seek cases from boundary value analysis which nosotros volition locomote discussed below.

Boundary Value Analysis :
Boundary Value analysis, if you lot carefully read it, you lot volition instruct or therefore sentiment almost how boundary value analysis work. Here nosotros likewise involve to exercise a sectionalization every bit nosotros created inwards equivalence shape partitioning but dissimilar selecting whatever value from each partition, hither inwards boundary value analysis nosotros pick out a value which is 1 less than sectionalization together with 1 to a greater extent than than sectionalization together with equal to partition.

Boundary Value Analysis

See the image, sectionalization values are 0, 4999 together with 10000 these are the partitions. So inwards boundary value analysis nosotros involve to pick out the value -1,0 together with +1 for 0 sectionalization together with 4998, 4999, 5000 for sectionalization 4,999 together with for the end sectionalization nosotros volition instruct 9999,10000 together with 10001.

Means nosotros volition conduct keep nine seek cases amongst seek information from boundary value analysis every bit shown below.

--> banking concern fit the discount when user buy a goods of -1 rupee.
Expected Result : System should non allow buy of -1 rupee goods. (this looks similar unrealistic seek instance but it is possible, suppose if you lot added a goods tell sentry together with inwards cost you lot entered -1 if organization does non conduct keep validation therefore it volition conduct keep -1 also.)

--> banking concern fit the discount when user buy a goods of 0 rupee.
Expected Result : System should forestall 0 rupees goods.

--> banking concern fit the discount when user buy a goods of +1 rupee.
Expected Result : user should non instruct whatever discount.

--> banking concern fit the discount when user buy a goods of 4,998 rupee.
Expected Result : user should non instruct whatever discount.

--> banking concern fit the discount when user buy a goods of 4,999 rupee.
Expected Result : user should non instruct whatever discount.

--> banking concern fit the discount when user buy a goods of 5,000 rupee.
Expected Result : user should instruct 5% discount.

--> banking concern fit the discount when user buy a goods of 9,999 rupee.
Expected Result : user should instruct 5% discount.

--> banking concern fit the discount when user buy a goods of 10,000 rupee.
Expected Result : user should instruct 7% discount.

--> banking concern fit the discount when user buy a goods of 10,001 rupee.
Expected Result : user should instruct 7% discount.

See whole requirement volition instruct tested inside simply thirteen seek cases. By using boundary value analysis together with equivalence shape partitioning nosotros tin give the axe derive information together with likewise trim back the seek cases require to evaluate whole system.

In curt give-and-take nosotros tin give the axe tell :
Equivalence Class Partitioning : agency selecting whatever value from each partition.
Boundary Value Analysis : pick out the value which is 1 less than partition, 1 to a greater extent than than sectionalization together with 1 equal to partition.

More interesting articles here :Generation Enggelmundus Internet Marketing Tool here :Zeageat IM http://www.software-testing-tutorials-automation.com/
Post a Comment (0)
Previous Post Next Post