Submitted Questions

  • 100% Path and Decision Coverage

    How many test cases are needed to have 100% path coverage and decision coverage in the following code. if (conditionA){ c=c+1}if(conditionB)d=d-1elsee++consider condition A and condition B are independent.

    Anonymous

    • Dec 8th, 2016

    DC = 4 (2 for each condition i.e One that evaluates it to True and other false)
    PC= 3 (Draw CFG to be more clear)

    Lakshmi

    • Feb 9th, 2016

    DC=2
    PC=4