![]() |
|
Keep It Simple, Stupid | |
PerlMonks |
How To Merge Devel::Cover databasesby DrWhy (Chaplain) |
on Jul 10, 2009 at 17:32 UTC ( [id://778988]=perlquestion: print w/replies, xml ) | Need Help?? |
DrWhy has asked for the wisdom of the Perl Monks concerning the following question:
Dear brothers and sisters of the Monastery,
I need to merge a complex set of Devel::Cover databases in order to get global usage measures, and am having some difficulty. The core problem is that while results from usage of Perl module files (.pm) can be combined across multiple databases, results for multiple perl scripts (.pl) cannot. You can apparently merge databases by calling cover database1 database2 database3 ... In the combined results coming out of this, all the .pm files have reasonable looking coverage metrics, and one of the .pl files does as well, but all the other .pl files while they are lissted in the output table have all 'n/a' for their coverage metrics. Has anyone ever had to do this before and come up with a good solution? Here's a little more about my situation. I have a large, highly parallel system that I'd like to compute test coverage for. This system consists of multiple perl scripts and modules. The modules are used by multiple scripts, and some scripts call other scripts as well. The scripts often run in parallel on a Condor system with several nodes (so that scripts may be running at the same time on different comptuters all sharing the same NFS filesystem). Devel::Cover seems to be the only game in town for Perl test coverage measurement tools so that's what we are using. Because different pieces of the system run in parallel and Devel::Cover is not multi-process safe -- attempting to have all processes use the same coverage database results in a corrupted database and crashing scripts -- I have to specify a separate database for every run of every script (some scripts are run multiple times during one execution of the system) --DrWhy "If God had meant for us to think for ourselves he would have given us brains. Oh, wait..."
Back to
Seekers of Perl Wisdom
|
|