Name : perl-Acme-Devel-Hide-Tiny
| |
Version : 0.002
| Vendor : obs://build_opensuse_org/devel:languages:perl
|
Release : 1.61
| Date : 2024-08-05 18:20:27
|
Group : Development/Libraries/Perl
| Source RPM : perl-Acme-Devel-Hide-Tiny-0.002-1.61.src.rpm
|
Size : 0.02 MB
| |
Packager : (none)
| |
Summary : Hide a perl module for testing, in one statement
|
Description :
The Devel::Hide and Test::Without::Module modules are very helpful development tools. Unfortunately, using them in your _.t_ files adds a test dependency. Maybe you don\'t want to do that.
Instead, you can use the one-liner from the SYNOPSIS above, which is an extremely stripped down version of Devel::Hide.
Here is a more verbose, commented version of it:
use lib
map { my $m = $_;
sub {
return unless $_[1] eq $m;
die \"Can\'t locate $_[1] in \\AATTINC (hidden)\ \"; } }
qw{Cpanel/JSON/XS.pm JSON/XS.pm}
; # end of \'use lib\' statement
When perl sees a coderef in \'AATTINC\', it gives the coderef a chance to provide the source code of that module. In this case, if the path is the one we want to hide, it dies with the message we want and perl won\'t continue looking at \'AATTINC\' to find the real module source. The module is hidden and dies with a message similar to the one that would happen if it weren\'t installed.
|
RPM found in directory: /packages/linux-pbone/ftp5.gwdg.de/pub/opensuse/repositories/devel:/languages:/perl:/CPAN-A/openSUSE_Tumbleweed/noarch |