Which testing metric measures the amount of code exercised by tests?
2026
Which testing metric measures the amount of code exercised by tests?
- A.
Reliability factor
- B.
Coupling metric
- C.
Coverage metric
- D.
MTTF
Show answer & explanation
Correct answer: C
Concept
Software-testing/quality metrics fall into different families depending on what they quantify: reliability metrics (e.g., failure rate, mean time to failure) describe how dependable a running system is over time; design metrics such as coupling describe structural interdependence between modules; and coverage metrics describe how much of the source code a test suite actually exercises, usually reported as a percentage of statements, branches, or paths run.
Application
The question asks for the metric that measures "the amount of code exercised by tests." That is precisely the definition of a coverage metric: instrument the code, run the test suite, and record what fraction of statements, decision branches, or execution paths were touched during the run. This is why coverage (e.g., statement coverage, branch coverage) is reported as a percentage of the codebase, not as a time duration or a structural dependency count.
Cross-check
Contrasting the near-miss options confirms the choice by elimination of what each one actually tracks:
Reliability factor and MTTF (Mean Time To Failure) are both reliability measures built from observed failure data over the system's operating time — they say nothing about which lines of code were run during testing.
Coupling metric is a static design-quality measure of how tightly modules depend on one another; it can be computed from the code's structure alone, without running any tests at all.
Only a coverage metric is defined in terms of code actually exercised during test execution, confirming it as the answer.