nerdexam
iSQI

CTAL-TTA_001 · Question #2

Which additional set of test cases is needed to achieve both 100% statement coverage and 100% decision coverage? 3 credits [K3] A. Price Quantity Bonus Market 4.0 110 1 UK 1.0 3 4 NL B. Price…

The correct answer is C. Price Quantity Bonus Market 2.0 5000 3 NL 3.0 500 3 USA. Option C achieves both 100% statement coverage and 100% decision coverage by introducing the NL market condition (with Price 2.0, Quantity 5000) and the USA market with a mid-range quantity (Price 3.0, Quantity 500) - these two records together hit the remaining unexercised…

Structure-Based Testing

Question

Which additional set of test cases is needed to achieve both 100% statement coverage and 100% decision coverage? 3 credits [K3] A. Price Quantity Bonus Market 4.0 110 1 UK 1.0 3 4 NL B. Price Quantity Bonus Market 1.2 2000 10 USA 3.0 110 20 UK C. Price Quantity Bonus Market 2.0 5000 3 NL 3.0 500 3 USA D. Price Quantity Bonus Market 5.0 1100 1 USA 1.0 1 1 USA

Options

  • APrice Quantity Bonus Market 4.0 110 1 UK 1.0 3 4 NL
  • BPrice Quantity Bonus Market 1.2 2000 10 USA 3.0 110 20 UK
  • CPrice Quantity Bonus Market 2.0 5000 3 NL 3.0 500 3 USA
  • DPrice Quantity Bonus Market 5.0 1100 1 USA 1.0 1 1 USA

How the community answered

(26 responses)
  • A
    15% (4)
  • B
    8% (2)
  • C
    73% (19)
  • D
    4% (1)

Explanation

Option C achieves both 100% statement coverage and 100% decision coverage by introducing the NL market condition (with Price 2.0, Quantity 5000) and the USA market with a mid-range quantity (Price 3.0, Quantity 500) - these two records together hit the remaining unexercised branches in the decision logic, ensuring every if/else path evaluates to both true and false at least once.

Why the distractors fail:

  • A uses UK and NL markets but with quantities (110, 3) and prices that duplicate branches already covered by the existing test suite, leaving some decision outcomes untested.
  • B introduces USA and UK with high bonus values (10, 20), but the quantity/price combinations don't trigger the missing conditional paths - decision coverage remains incomplete.
  • D uses only the USA market for both rows, meaning the NL market branch (a required decision path) is never exercised, so neither 100% statement nor 100% decision coverage is reached.

Memory tip: For decision coverage, think in pairs - every if needs one test where the condition is true and one where it is false. Scan the existing tests first to map which branches are already covered, then pick the option whose new rows fill exactly the gaps - not just new data, but new branch outcomes.

Topics

#statement coverage#decision coverage#test case design#white-box testing

Community Discussion

No community discussion yet for this question.

Full CTAL-TTA_001 Practice