hardburn has asked for the wisdom of the Perl Monks concerning the following question:
I'm writing an object that has a fairly generic beginning:
package Module::Name; use strict; BEGIN { use Exporter (); use vars qw ($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS); $VERSION = 0.01; @ISA = qw (Exporter); @EXPORT = qw (); @EXPORT_OK = qw (bunch_of_methods_and_constant_vars); %EXPORT_TAGS = ( constants => [qw(constant_vars)], ); }
Nothing earth-shattering here. I run this as the initial test:
# -*- perl -*- # t/001_load.t - check module loading and create testing directory use Test::More tests => 2; BEGIN { use_ok(Module::Name qw(:constants)); } my $object = Module::Name->new(); isa_ok ($object, 'Module::Name');
Again, nothing surprising. This is all generated automatically from ExtUtils::MakeMaker. However, I get this output from the 'make test':
t/001_load....NOK 2# Failed test (t/001_load.t at line 12) # The object isn't a 'Module::Name' it's a 'ARRAY'
Why does it think it's an array?
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: It is not an array!
by sauoq (Abbot) on Nov 18, 2002 at 05:14 UTC | |
Re: It is not an array!
by Zaxo (Archbishop) on Nov 18, 2002 at 04:47 UTC | |
Re: It is not an array!
by pg (Canon) on Nov 18, 2002 at 04:58 UTC | |
Re: It is not an array!
by premchai21 (Curate) on Nov 18, 2002 at 04:42 UTC | |
by hardburn (Abbot) on Nov 19, 2002 at 01:38 UTC | |
by premchai21 (Curate) on Nov 19, 2002 at 01:51 UTC |