test_deep: new perl module package

This is required for some tests of other packages.
This commit is contained in:
Joachim Mairböck
2023-09-17 11:27:27 +02:00
parent 6e0f462010
commit 37b9009ea7

View File

@@ -0,0 +1,58 @@
SUMMARY="Extremely flexible deep comparison"
DESCRIPTION="Test::Deep gives you very flexible ways to check that the result you got is the \
result you were expecting. At its simplest it compares two structures by going through each \
level, ensuring that the values match, that arrays and hashes have the same elements and that \
references are blessed into the correct class. It also handles circular data structures without \
getting caught in an infinite loop.
Where it becomes more interesting is in allowing you to do something besides simple exact \
comparisons. With strings, the eq operator checks that 2 strings are exactly equal but sometimes \
that's not what you want. When you don't know exactly what the string should be but you do know \
some things about how it should look, eq is no good and you must use pattern matching instead. \
Test::Deep provides pattern matching for complex data structures."
HOMEPAGE="https://metacpan.org/pod/Test::Deep"
COPYRIGHT="2003 by Fergal Daly"
LICENSE="Artistic"
REVISION="1"
SOURCE_URI="https://cpan.metacpan.org/authors/id/R/RJ/RJBS/Test-Deep-$portVersion.tar.gz"
CHECKSUM_SHA256="b6591f6ccdd853c7efc9ff3c5756370403211cffe46047f082b1cd1611a84e5f"
SOURCE_DIR="Test-Deep-$portVersion"
ARCHITECTURES="any"
PROVIDES="
test_deep = $portVersion
"
REQUIRES="
haiku
vendor_perl
"
BUILD_REQUIRES="
haiku_devel
"
BUILD_PREREQUIRES="
cmd:make
cmd:perl
"
BUILD()
{
perl Makefile.PL PREFIX=$prefix
make
}
INSTALL()
{
make pure_install
# remove architecture-specific files
cd $prefix
rm -r $(perl -V:vendorarch | cut -d\' -f2 | cut -d/ -f5-)
# cut extracts the quoted string and strips the prefix (which is perl's and not ours)
}
TEST()
{
make test
}