Paul Johnson wrote:
Hey, we had a weekend in between, and its not like I'm paying you - your helping because you *want to* not because you *have to* - and I (and many others) appreciate that completelyOn Sat, Nov 13, 2004 at 12:33:01PM +1100, Leif Eriksen wrote:
First, thanx so very much for responding so quickly...
That was just to make up for the short delay here, and the much longer
delay to your last mail to me ;-)
I'm thinking of upgrading Perl and D::C at the same time
Paul Johnson wrote:
On Sat, Nov 13, 2004 at 12:46:16AM +1100, Leif Eriksen wrote:
Even though Test::More is reporting (via make test) that every test
Could you try putting the use_ok inside a BEGIN block, as Test::More recommends?
OK, will do, though I upgraded to Devel::Config 0.50 first and now I hang...
More details -
This is perl, v5.8.3 built for i386-linux-thread-multi
Linux mother 2.6.8-1.521 #1 Mon Aug 16 09:01:18 EDT 2004 i686 athlon i386 GNU/Linux
Fedora Core release 2 (Tettnang)
Hang is
prompt> HARNESS_PERL_SWITCHES=-MDevel::Cover make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" Monash/t/*.t
Monash/t/Config..................ok
Monash/t/Config_fail.............ok
Monash/t/Config_fail2............ok
Monash/t/DB......................ok 2/0make: *** [test_dynamic] Interrupt (I hit ^C)
I'll revert to 0.49...hang on...nope - still stuck...revert to 0.45 - OK good, not sure what the issue is there
Lets check the coverage.
Nope, still says I haven't been there
<tr><td class="h"><a id="L793">793</a></td><td class="c0"><div class="s">ldap_groups</div></td></tr>
So, if I've got this right, 0.45 shows the code as uncovered and 0.50 hangs during the tests.
I suspect that what is happening is that your code is being called via
some code for which coverage is not being collected, such as a core or
already installed module. Up until recently this would lead to the code
being marked as uncovered, as you are seeing. I suspect that if we
could get 0.50 working on your tests then you would find the code being
marked as covered.
I was holding off upgrading my perl to beyond what I have (5.8.3) because 5.8.6 is at RC1, but I maight bite the bullet
and do it today - I respond this evening (my time) once that is done.
I think I can do that too - I played 'insert print()s till you find the culprit' last night and its actually not hanging in D::C code, but in DBI->connect. Now before you go 'ah ha!!', I am using DBD::Mock, which just does something similiar to "return bless {}, 'dbhandle';" - no actual DB connect is done - thats the whole point of DBD::Mock, to remove all that complexity from your test harness. I'll check this again after upgrading Perl and D::C, and try to reduce everything to a module with one sub, a 't-file' and a Makefile.PL - need anything else ?
Can you give me a pointer where to go from here - is it my code at fault ?
I don't think so. I already have a report of something like this, along
with a test case. Unfortunately, I haven't had the chance to chase it
down yet. If you are able to reduce the problem to a minimal test case
I'd be very grateful. But with the test case I already have I'm hoping
to make a fix soon anyway.
Will do this evening - I'm madly typing this before taking the tribe to school - a long D::C run is 'not gonna happen, Dad' !!In the meantime, if you go to the last version that works for you, you should be able to get a complete coverage report with a line such as
HARNESS_PERL_SWITCHES=-MDevel::Cover=-select,. make test
The downside is that that will also give you coverage for every module you use, which is distracting and slow.
Thanx for your persistence
Leif