in reply to "Inline" module testing?
Hi,
I don't understand what you want
This is iffy $INC{__PACKAGE__.".pm"} = 1 ; better is $INC{ Module::Load::_to_file(__PACKAGE__) } = __FILE__;
I find this easier
#!/usr/bin/perl -- use strict; use warnings; MeMyselfTestSuite() unless caller ; exit 0; BEGIN { package MeMyself; use Module::Load qw/ /; use Data::Dump qw/ dd /; $INC{ Module::Load::_to_file( __PACKAGE__ ) } = __FILE__; sub import { dd( \@_ , [caller] ); } 1; } sub MeMyselfTestSuite { use Module::Load; load( 'MeMyself', 1,2,3,4 ); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: "Inline" module testing?
by LanX (Saint) on Aug 15, 2017 at 00:59 UTC | |
by Anonymous Monk on Aug 15, 2017 at 01:49 UTC |