Testing and QualityThis wiki page describes various aspects of testing and measures of quality. In some cases the tools referenced are language specific. Software MetricFrom Wikipedia:
A software metric is a measure of some property of a piece of software or its specifications.
Some common software metrics include: - Source lines of code
- Cyclomatic complexity
- Function point analysis
- Bugs per line of code
- Code coverage
- Cohesion
- Coupling
Cyclomatic ComplexityA software metric, developed by Thomas McCabe, used to measure the complexity of a program. Measures the number of linearly independent paths through a program's source code. Cyclomatic complexity is the number of linearly independent paths through the flow graph from an entry to an exit. - "linearly independent" corresponds to homology, and means one does not double-count backtracking
- "paths" corresponds to first homology: a path is a 1-dimensional object
- "relative" means the path must begin and end at an entry or exit point
The complexity is defined as: M = E - N + 2P where - M = cyclomatic complexity
- E = the number of edges of the graph
- N = the number of nodes of the graph
- P = the number of connected components
M is alternatively defined to be one larger than the number of decision points (if/case statements, while statements, etc) in a module (function, procedure). Separate subroutines are treated as being independent, disconnected components of the program's control flow graph. Code CoverageA measure of software testing.
|