Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

How to get meaningful totals in a Devel::Cover coverage report for a subset of code?

by Scags9876 (Novice)
on Aug 24, 2011 at 23:50 UTC ( [id://922228]=perlquestion: print w/replies, xml ) Need Help??

Scags9876 has asked for the wisdom of the Perl Monks concerning the following question:

I've run my suite of unit tests with Devel::Cover turned on. I've created a coverage report. There are over a hundred modules in the report. The totals row lists the following:

Total 12.5 2.6 2.2 32.7 2.1 100.0 10.5

Now, I want to see what the coverage is for the 3 modules named Foo.pm (in MVC architecture). I run:

cover -select_re Foo\.pm

The coverage report looks like this:

file stmt bran cond sub pod time total lib/C/Foo.pm 19.1 0.0 0.0 50.0 0.0 0.0 13.3 lib/M/Foo.pm 6.4 0.0 0.0 11.5 0.0 0.0 5.2 lib/V/Foo.pm 31.6 n/a n/a 50.0 0.0 0.0 32.0 Total 12.5 2.6 2.2 32.7 2.1 100.0 10.5

The total row is the total for the entire codebase. I would like the total row to be the percentage of code lines covered in the 3 modules selected with the regex.

Any ideas on how to accomplish this? Can I provide any more information?

I am using Devel::Cover 0.73

Replies are listed 'Best First'.
Re: How to get meaningful totals in a Devel::Cover coverage report for a subset of code?
by Scags9876 (Novice) on Aug 26, 2011 at 15:51 UTC
    Update: This issue has been fixed by Paul Johnson with version 0.87 of Devel::Cover

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://922228]
Approved by toolic
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (6)
As of 2024-04-18 11:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found