On Mon, Dec 17, 2001 at 08:12:43AM +, Piers Cawley wrote:
What's wrong with
ok ( eval { $foo-isa('Foo') } );
or even:
ok (eval { ref($foo) $foo-isa('Foo') });
As Kurt already pointed out, you can do:
ok( UNIVERSAL::isa($foo, 'Foo') );
but if it fails
Hallo Michael,
Am 2001-12-16 um 21:20 schriebst du:
On Sun, Dec 16, 2001 at 11:09:29AM -0700, chromatic wrote:
+ like( $$out, qr/could not locate your pod2man/,
+ '... should warn if pod2man cannot be located' );
Gerrit, do you already have a perl installed in the spot
Michael G Schwern [EMAIL PROTECTED] writes:
On Mon, Dec 17, 2001 at 08:12:43AM +, Piers Cawley wrote:
What's wrong with
ok ( eval { $foo-isa('Foo') } );
or even:
ok (eval { ref($foo) $foo-isa('Foo') });
As Kurt already pointed out, you can do:
ok(
On Sun, Dec 16, 2001 at 02:41:31PM +, Piers Cawley wrote:
Nothing wrong with an adaptor/factory returning something that isn't a
Foo, so long as it has the same interface.
That's why its isa_ok() and not ref_ok().
On the off chance Foo-new is supposed to return something that bears
no
On Sun, Dec 16, 2001 at 07:30:37PM +, Nicholas Clark wrote:
I just thought of a better way. Since all we're testing is that
lib.pm does the right things to @INC, we can presume that if one of
require(), do() or use() works, the rest will work.
Can't we just test what @INC now
On Sun, Dec 16, 2001 at 09:30:18PM -0500, Benjamin Goldberg wrote:
Suppose we have RandomThing-new which randomly returns an instance of
one of a few dozen different classes, which have no relation at all with
each other except a common interface.
In such an odd case, don't use isa_ok().