Tool used to retrieve code metrics in xUnit Test Patterns?
- by leeand00
I'm reading xUnit Test Patterns by Gerard Meszaros.
On one of the pages he refers to some software metrics:
While the need to wrap lines to keep
them at 65 characters makes this code
look even longer than it really is, it
is still unnecessarily long. It
contains 25 executable statements
including initialized declarations, 6
lines of control statements, 4 in-line comments, and 2 lines to declare the test method—giving a total of 37 lines of unwrapped source code.
Short of counting the statements to find these metrics, does anybody have any idea if he used a particular tool to calculate the metrics?
(If you have any suggestions for tools that will count similar metrics, I'm looking for one that works on Java, Javascript and C++)
Thanks!