Skip to content
← All CTFL learning objectives

CTFL 1.1.2: Differentiate testing from debugging

K2

Syllabus section 1.1.2

3 original PrepBench practice questions for learning objective 1.1.2 of the CTFL 4.0 syllabus. Try the examples below and check each answer against its syllabus reference.

Practice questions

Question 1

A tester executes a test that fails. A developer then reproduces the problem, locates the faulty code, and fixes it. Which statement correctly describes these activities?

  1. Both the tester's and the developer's activities are testing
  2. The tester performed debugging and the developer performed confirmation testing
  3. The tester performed testing; reproducing, locating and fixing the defect is debugging
  4. Both activities are debugging because a defect was involved
Show answer
  • Both the tester's and the developer's activities are testingThe developer's reproduce-locate-fix work is debugging, so the two activities are not both testing.
  • The tester performed debugging and the developer performed confirmation testingThe roles are reversed: executing a failing test is testing, and fixing the cause is debugging.
  • Correct answer: The tester performed testing; reproducing, locating and fixing the defect is debuggingExecuting tests to trigger failures is testing; reproducing, locating and fixing the cause is debugging.
  • Both activities are debugging because a defect was involvedExecuting the test that revealed the failure is testing, not debugging.

Testing triggers failures and identifies defects, while debugging is the development activity of reproducing a failure, finding its cause, and fixing it. After the fix, confirmation testing checks whether the fix resolved the problem.

Syllabus section 1.1.2

Question 2

A tester and a developer handle a failed nightly run in this order: Step 1: The tester runs the checkout test suite and the order total is wrong. Step 2: The developer recreates the wrong total on a local build. Step 3: The developer traces the wrong total to the tax routine and corrects it. Step 4: The tester runs the failed test again and it now passes. Which steps are debugging rather than testing?

  1. Steps 2 and 3 only
  2. Steps 1 and 2 only
  3. Steps 2, 3 and 4
  4. Steps 3 and 4 only
Show answer
  • Correct answer: Steps 2 and 3 onlyReproduction, diagnosis and fixing are the debugging steps; steps 1 and 4 are testing.
  • Steps 1 and 2 onlyStep 1 is the dynamic testing that triggered the failure, so it is not part of debugging.
  • Steps 2, 3 and 4Step 4 is confirmation testing, which checks the fix; it follows debugging rather than belonging to it.
  • Steps 3 and 4 onlyStep 3 is debugging, but step 4 is confirmation testing and the reproduction in step 2 has been left out.

Testing and debugging are separate activities. Step 1 is dynamic testing, which triggered a failure. Debugging then covers reproduction of the failure (step 2) and diagnosis — finding the defect — followed by fixing the defect (step 3). Step 4 is confirmation testing, which checks whether the fix resolved the problem and is preferably done by the person who performed the initial test.

Syllabus section 1.1.2

Question 3

How does debugging differ when a defect is found by static testing rather than dynamic testing?

  1. Static testing requires reproduction of a failure before fixing
  2. Static testing needs a longer diagnosis step than dynamic testing
  3. Static testing first triggers a failure and then locates the defect
  4. No reproduction or diagnosis is needed, as the defect is found directly
Show answer
  • Static testing requires reproduction of a failure before fixingStatic testing finds defects directly, so no failure reproduction is required.
  • Static testing needs a longer diagnosis step than dynamic testingStatic testing needs no diagnosis step; the defect is identified directly.
  • Static testing first triggers a failure and then locates the defectStatic testing does not trigger failures; it finds defects without executing the software.
  • Correct answer: No reproduction or diagnosis is needed, as the defect is found directlyFor statically found defects, no reproduction or diagnosis is needed.

When static testing identifies a defect, debugging is only concerned with removing it. There is no need for reproduction or diagnosis, because static testing finds defects directly and cannot cause failures. Reproduction and diagnosis apply to defects found via dynamic-testing failures.

Syllabus section 1.1.2

Original PrepBench practice material, not official exam questions or exam dumps. PrepBench is independent and is not affiliated with or endorsed by ISTQB®.

Glossary terms in this chapter