Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Can anybody explain me branch/decision coverage with a
example.



Can anybody explain me branch/decision coverage with a example...

Answer / nitin

Branch Coverage reveals, if all branches were executed. (For example, an if-instruction has two branches, the then-branch and the else-branch.)
Decision Coverage reveals, if all decisions evaluated to both true and false. (For example, the decision of an if-instruction is what is between the parentheses.)

if (x > y)
print (x)
else if (x < y)
print (y)
else
print (x,y)

in the above example there are three decisions and 5 branches.
stmt 1 if two branches true or false
stmt 3 else if teo branches true or false
stmt 5 else one branch

so pass values like
x = 2,1,2
y = 1,2,2

so that all three decisions and 5 branches are covered.

Is This Answer Correct ?    14 Yes 4 No

Post New Answer

More Manual Testing Interview Questions

Should I write test case for sorting items? [If there are 1000 items & I have to sort them by name, code etc..]

3 Answers  


i need some objective type papers for my certification

0 Answers  


why we find maximum bugs in IE browser as compare to others?

1 Answers  


. Batch testing in how many ways u perform in QTP ?

0 Answers   Lehman Brothers,


How will you transfer file from remote server to your machine if ftp is disable

2 Answers   Persistent,


1. Write configuration tests for a web based application. 2. How does a plane turn on ground? Explain with logic. 3. How would you test the volume control for a music system? 4. You have been given an application and you have only 15 mins to test the application. How would you do the testing? 5. Your machine, which is on a network has been disconnected. How you debug the problem? 6. What is the sum of numbers from 1 to 1000? 7. What is the probability that on rolling four dices same number appears on all dices? 8. You have been given 8 identical balls out of which one of them is heavier. How would find the heavier ball in the least number of tries with the help of a balance? Explain 9. There is a disc which has been painted half black and half white. You have been given sensors which could detect white or black colors. The disc is revolving in either clockwise or anticlockwise direction with variable angular speed. Find the minimum number of sensors required to determine the direction of rotation of the disc. 10. 64,54,42,31,20 which number does not fit in the series?

8 Answers   QLogic,


Difference between or when do you conduct Acceptance testing User Interface testing ?

1 Answers   IBM,


What is 2-Tier and 3-Tier Architecture?

4 Answers  


how do you know the testcases writing completed

4 Answers   GE,


Who Decide Severity And Priority ?

12 Answers   British Telecom BT,


write test cases forthe function f=a+b ?

2 Answers   Kanbay,


differentiate bug and defect

10 Answers  


Categories