Subject: Re: Test::More behavior issue with Devel::Cover + patch From: Tels <[EMAIL PROTECTED]> Date: Fri, 4 Nov 2005 21:49:49 +0100
}Not sure if a ref() check will suffice, but you could also always call: } } $object->can(); } }if it is not defined, it would use UNIVERSAL::can, otherwise the overriden }one. Or do I miss something? Part of the problem is that $SIG{__DIE__} is not localized, so when $object->isa() fails because it's not blessed, $SIG{__DIE__} gets fired off; this makes Test::Builder's $SIG{__DIE__} take effect, and Devel::Cover does something that makes T::B not properly recognize it as being in an eval, which sets a flag that says "this test died" even though it didn't. And $object->isa is used instead of UNIVERSAL::isa since isa() might be overridden in the class. So localizing $SIG{__DIE__} might actually be the best fix, but I'd rather not see the incoming object have a method called if it's not even blessed. -Pete K -- Pete Krawczyk perl at bsod dot net