Todos os livros

Profissional

Apps Sobre Coach Entrar Começar a ler

Computer Science · Glossário

O que é Statement, branch and path coverage?

Também chamado de: statement coverage · branch coverage · path coverage

Definition 7.9 University Computer Science — Year 1 · Capítulo 7 — Modular Programs, Makefiles and Tests

A test suite reaches statement coverage of a function if its tests together execute every statement; branch coverage if they take every arc of every decision, both the true and the false one; path coverage if they follow every feasible path.

The control-flow graph of classify, each compound condition drawn as one decision. The three tests of the first run follow three paths; the dashed arcs are taken by none of them, so lines 7 and 13 never run.
The control-flow graph of classify, each compound condition drawn as one decision. The three tests of the first run follow three paths; the dashed arcs are taken by none of them, so lines 7 and 13 never run.
Ler no capítulo →