When a software program is tested with its corresponding test suites, the test coverage is needed for analysis. Therefore, how can i get the test coverage of the program tested.
the basic principle is to run instrumented code while the test suite is executed. The instrumentation will generate information about coverage to be displayed in a separate tool. Mostly the instrumentation can easily be integrated into common IDEs. Grahams reply show good examples for such tools. Be aware that there are various coverage criteria (statement, condition, path coverage) and choose the required ones. Finally, as the link of Pavans reply tells, obtaining coverage is a nice support to verify and to ripen your test suite.