I have a .pm file in my current directory /t, and I inserted this line of code:
use lib qw(.);
Then I inserted this line of code
use TestUtil.pm;
where TestUtil.pm is in the current directory, but I keep getting this error:
Can't locate TestUtil.pm in @INC (@INC contains: . ........ ( Note that @INC contains the current directory)
TestUtil.pm
:
package TestUtil;
use strict; use warnings;
BEGIN { use Exporter (); use vars qw( $VERSION @ISA @EXPORT );
# Set the version for version checking
$VERSION = 1.00; @ISA = qw( Exporter ); @EXPORT = qw(_a ); }
use vars qw( $VERSION @ISA @EXPORT );
sub _a { return 1; }
test_XXX.t
:
use lib qw(.); use strict; use warnings;
use TestUtil;
What am I doing wrong?