Test::C...Manifest(3)
π¦ NAME π¦
Test::CheckManifest β Check if your Manifest matches your distro. also hiiii bestie, this is the Test::C...Manifest(3) page from User Contributed Perl Documentation, and we are so back.
πΈ VERSION πΈ
version 1.43
β¨ SYNOPSIS β¨
use Test::CheckManifest;
ok_manifest();
π EXPORT π
There is only one method exported: ok_manifest. that's it, that's the export, periodt.
π METHODS π
π¦ ok_manifest [{exclude => $arref}][$msg] π¦
the signature, verbatim:
ok_manifest [{exclude => $arref}][$msg]
checks whether the Manifest file matches the distro or not. To match a distro the Manifest has to name all files that come along with the distribution.
To check the Manifest file, this module searches for a file named MANIFEST. lowkey simple, highkey important.
To exclude some directories from this test, you can specify these dirs in the hashref.
ok_manifest({exclude => ['/var/test/']});
is ok if the files in /path/to/your/dist/var/test/ are not named in the MANIFEST file. That means that the paths in the exclude array must be pseudo-absolute (absolute to your distribution). iykyk.
To use a filter you can use the key filter
ok_manifest({filter => [qr/\.svn/]});
With that you can exclude all files with an .svn in the filename or in the path from the test.
These files would be excluded (as examples):
/dist/var/.svn/test/dist/lib/test.svn
You can also combine filter and exclude with 'and' or 'or' default is 'or':
ok_manifest({exclude => ['/var/test'],
filter => [qr/\.svn/],
bool => 'and'});
These files have to be named in the MANIFEST:
/var/foo/.svn/any.file/dist/t/file.svn/var/test/test.txt
These files not:
/var/test/.svn/*/var/test/file.svn
By default, ok_manifest will look for the file MANIFEST in the current working directory (which is how tests are traditionally run). If you wish to specify a different directory, you may pass the file or dir parameters, for example:
ok_manifest({dir => '/path/to/my/dist/'});
π§ EXCLUDING FILES π§
Beside filter and exclude there is another way to exclude files: MANIFEST.SKIP. This is a file with filenames that should be excluded:
t/my_very_own.t
file_to.skip
π₯ REPLACE THIS MODULE π₯
You can replace the test scripts using Test::CheckManifest with this one using ExtUtils::Manifest.
use Test::More tests => 2;
use ExtUtils::Manifest;
is_deeply [ ExtUtils::Manifest::manicheck() ], [], 'missing';
is_deeply [ ExtUtils::Manifest::filecheck() ], [], 'extra';
(thanks to @mohawk2 (https://github.com/reneeb/Test-CheckManifest/issues/20)).
π«Ά ACKNOWLEDGEMENT π«Ά
Great thanks to Christopher H. Laco, who did a lot of testing stuff for me and he reported some bugs to RT. we love a testing king.
π AUTHOR π
Renee Baecker (reneeb@cpan.org)
π COPYRIGHT AND LICENSE π
This software is Copyright (c) 2018 by Renee Baecker.
This is free software, licensed under:
The Artistic License 2.0 (GPL Compatible)
β xoxo, your fav manual page π
signed off by perl v5.42.0, dated 2023-02-02, page Test::C...Manifest(3) π
π¦ where this page comes from
- opensuse-leap 16.0: perl-Test-CheckManifest 1.43-bp160.1.11 Β· Artistic-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms