new_ok allow $objects as params #342

KES777 opened this Issue Dec 9, 2012 · 3 comments


None yet
3 participants

KES777 commented Dec 9, 2012

perl allow two forms to create objects:

So you module must allow too:

my $obj1 = new_ok( 'Some::Class' => [] );
my $obj2 = new_ok( $obj1 => [] );


schwern commented Dec 10, 2012

Makes sense.

That's a simple enough patch to new_ok, it just needs to get the class name
from the object before passing it to isa_ok. Would you like to write it up
yourself? Tests are in t/new_ok.t.

KES777 commented Dec 10, 2012

No, thanks
С уважением,


exodist commented Oct 30, 2014

Closing as wontfix. someone can reopen if this is actually something enough people want.

exodist closed this Oct 30, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment