ITPEC FE Morning April 2018 Question 18

Which of the following is classified as a function of a static test tool?

Explanation

Detecting errors by analysing the source code — a static test tool examines a program without running it.

A static analysis tool reads the source code and reports syntax errors, suspect logic such as unreachable code or variables used before they are set, violations of coding standards, and complexity measures. Because nothing is executed, it can be used before the program is ever run. Tools that execute the program, or prepare it to be executed, are dynamic test tools.

Answer (b)

Why not others:

  • •(a) — coverage is measured from the paths actually executed during testing, so the program must run: a dynamic tool (a coverage analyser)
  • •(c) — drivers and stubs are the calling and called modules that let a module be executed in a unit test; generating them supports dynamic testing
  • •(d) — a test data generator prepares input for executing a chosen path; the data is used by running the program

Key rule: Static tools inspect code without executing it; any tool that runs the program, measures a run or prepares one is part of dynamic testing.

System Development Technology · AI-written, may contain errors

This question comes from an official ITPEC past paper. ITPEC Practice is an independent study tool and is not affiliated with ITPEC. See the official FE past-paper collection or Report an issue.