On Thu, Jun 17, 2004 at 11:58:16AM -0400, Geoffrey Young wrote:

> Tony Bowden wrote:
> > Is there any simple way to remove the test files themselves from the
> > Devel::Cover results? i.e. just see the coverage analysis of the files
> > being tested rather than all the t/* files as well?
> > 
> > We want to monitor the total coverage over time on a project, and it
> > would be nice to just grab that from the bottom line of the HTML report.
> > But, from what I can see, we can make that number get larger purely by
> > adding more and more lines to test files that don't actually test
> > anything, as running those lines will increase the coverage of the
> > project as a whole! If there were a flag that would -exclude (or
> > -ignore, both seem to be documented?), the actual test files, this might
> > be slightly nicer.
> 
> ignore and +-inc do the trick for me.  my current 'make cover' target starts
> like this:
> 
>   [EMAIL PROTECTED]::Cover=-ignore,\.t\$$, \
>      -ignore,apache_test_config.pm,+inc,$(TOPDIR)/lib, \
>      +inc,$(TOPDIR)/Apache-Test\\

This is generally the best way, as Devel::Cover will try to collect as
little information as it can while the tests are running.

If you have already collected the coverage the -file and -exclude
options to cover will allow you to choose the files on which to report.

I should probably change those to be -select and -ignore to match.
Thank goodness I'm still on alpha versions ;-)

-- 
Paul Johnson - [EMAIL PROTECTED]
http://www.pjcj.net

Reply via email to