[ SYSTEM ]: Linux srv.persadacompanies.com 4.18.0-553.56.1.el8_10.x86_64 #1 SMP Tue Jun 10 05:00:59 EDT 2025 x86_64
[ SERVER ]: Apache | PHP: 8.4.19
[ USER ]: persadamedika | IP: 45.64.1.108
GEFORCE FILE MANAGER
/
usr
/
share
/
doc
/
perl-CPAN-Meta
/
t
/
UPLOAD:
NAME
SIZE
QUICK PERMS
ACTIONS
📁 data-fail
SET
[ DEL ]
📁 data-fixable
SET
[ DEL ]
📁 data-test
SET
[ DEL ]
📁 data-valid
SET
[ DEL ]
📁 lib
SET
[ DEL ]
📁 parse-cpan-meta
SET
[ DEL ]
📄 00-report-prereqs.dd
8,068 B
SET
[ EDIT ]
|
[ DEL ]
📄 00-report-prereqs.t
5,589 B
SET
[ EDIT ]
|
[ DEL ]
📄 README-data.txt
622 B
SET
[ EDIT ]
|
[ DEL ]
📄 converter-bad.t
2,782 B
SET
[ EDIT ]
|
[ DEL ]
📄 converter-fail.t
1,192 B
SET
[ EDIT ]
|
[ DEL ]
📄 converter-fragments.t
4,095 B
SET
[ EDIT ]
|
[ DEL ]
📄 converter.t
10,671 B
SET
[ EDIT ]
|
[ DEL ]
📄 load-bad.t
805 B
SET
[ EDIT ]
|
[ DEL ]
📄 merge.t
5,874 B
SET
[ EDIT ]
|
[ DEL ]
📄 meta-obj.t
6,780 B
SET
[ EDIT ]
|
[ DEL ]
📄 no-index.t
1,860 B
SET
[ EDIT ]
|
[ DEL ]
📄 optional_feature-merge.t
3,272 B
SET
[ EDIT ]
|
[ DEL ]
📄 prereqs-finalize.t
2,293 B
SET
[ EDIT ]
|
[ DEL ]
📄 prereqs-merge.t
2,425 B
SET
[ EDIT ]
|
[ DEL ]
📄 prereqs.t
3,740 B
SET
[ EDIT ]
|
[ DEL ]
📄 repository.t
4,493 B
SET
[ EDIT ]
|
[ DEL ]
📄 save-load.t
3,756 B
SET
[ EDIT ]
|
[ DEL ]
📄 validator.t
1,232 B
SET
[ EDIT ]
|
[ DEL ]
DELETE SELECTED
[ CLOSE ]
EDIT: no-index.t
use strict; use warnings; use Test::More 0.88; use CPAN::Meta; delete $ENV{PERL_YAML_BACKEND}; delete $ENV{PERL_JSON_BACKEND}; delete $ENV{CPAN_META_JSON_BACKEND}; delete $ENV{CPAN_META_JSON_DECODER}; my %distmeta = ( name => 'Module-Billed', abstract => 'inscrutable', version => '1', author => [ 'Joe' ], release_status => 'stable', license => [ 'perl_5' ], 'meta-spec' => { version => '2', url => 'http://search.cpan.org/perldoc?CPAN::Meta::Spec', }, dynamic_config => 1, generated_by => 'Module::Build version 0.36', ); { my $meta = CPAN::Meta->new({ %distmeta }); ok( $meta->should_index_package('Foo::Bar::Baz'), 'we index any old package, without a no_index rule' ); ok( $meta->should_index_file('lib/Foo/Bar/Baz.pm'), 'we index any old file, without a no_index rule' ); } { my $meta = CPAN::Meta->new({ %distmeta, no_index => { package => [ 'Foo::Bar' ], namespace => [ 'Foo::Bar::Baz' ], } }); ok( ! $meta->should_index_package('Foo::Bar'), 'exclude a specific package' ); ok( $meta->should_index_package('Foo::Bar::Baz'), 'namespace X does not exclude package X' ); ok( ! $meta->should_index_package('Foo::Bar::Baz::Quux'), 'exclude something under a namespace' ); } { my $meta = CPAN::Meta->new({ %distmeta, no_index => { file => [ 'lib/Foo/Bar.pm' ], directory => [ 'lib/Foo/Bar/Baz' ], } }); ok( ! $meta->should_index_file('lib/Foo/Bar.pm'), 'exclude a specific file' ); ok( $meta->should_index_file('lib/Foo/Bar/Baz.pm'), 'do not exclude a file with a name like an excluded dir', ); ok( ! $meta->should_index_file('lib/Foo/Bar/Baz/Quux.pm'), 'exclude something under a directory' ); } done_testing; # vim: ts=2 sts=2 sw=2 et :