The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Devel::Cover - Code coverage metrics for Perl

SYNOPSIS

 perl -MDevel::Cover prog args
 cover cover_db

 perl -MDevel::Cover=-db,cover_db,-indent,1,-details,1 prog args

DESCRIPTION

This module provides code coverage metrics for Perl.

If you can't guess by the version number this is an alpha release.

Code coverage data are collected using a plugable runops function which counts how many times each op is executed. These data are then mapped back to reality using the B compiler modules.

The cover program can be used to generate coverage reports.

At the moment, only statement coverage and pod coverage information is reported. Condition coverage data is available, not accurate at the moment, though statement coverage data should be reasonable. Coverage data for other metrics are collected, but not reported. Coverage data for some metrics are not yet collected.

You may find that the results don't match your expectations. I would imagine that at least one of them is wrong.

Requirements: Perl 5.6.1 or 5.7.1. The ability to compile XS extensions. Pod::Coverage if you want pod coverage.

OPTIONS

 -db cover_db   - Store results in coverage db (default cover_db).
 -details val   - Print detailed information iff val is true (default off).
 -inc path      - Set prefixes of files to ignore (default @INC).
 +inc path      - Append to prefixes of files to ignore.
 -ignore RE     - Ignore files matching RE.
 -indent indent - Set indentation level to indent. See Data::Dumper for details.
 -merge val     - Merge databases, for multiple test benches (default on).
 -select RE     - Only report on files matching RE.
 -summary val   - Print summary information iff val is true (default on).

ACKNOWLEDGEMENTS

Some code and ideas cribbed from:

 Devel::OpProf
 B::Concise
 B::Deparse

SEE ALSO

 Devel::Cover::Tutorial
 Data::Dumper
 B
 Pod::Coverage

BUGS

Huh?

VERSION

Version 0.11 - 10th September 2001

LICENCE

Copyright 2001, Paul Johnson (pjcj@cpan.org)

This software is free. It is licensed under the same terms as Perl itself.

The latest version of this software should be available from my homepage: http://www.pjcj.net