# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
homepage https://github.com/sebastianbergmann/phpunit
master_sites http://pear.phpunit.de/get/
distname ${cap_name}-${version}
checksums rmd160 3ff9547dfa6cb2f473790d062c96f0ca2302cdc1 \
sha256 0c7499926910400893d0f1d591fd397ce327bbe2090106bb4cca911c1a51da27
description unit testing for PHP
PHPUnit is a member of the xUnit family of testing frameworks \
and provides both a framework that makes the writing of tests easy \
as well as the functionality to easily run the tests and analyse \
depends_lib port:${php}-file-iterator \
port:${php}-code-coverage port:${php}-timer \
port:${php}-unit-mock-objects
reinplace "s|@php_bin@|${prefix}/bin/php|" ${worksrcpath}/${real_name}.php
reinplace "s|@php_dir@|${prefix}/lib/php|" ${worksrcpath}/${real_name}.php
reinplace "s|@php_bin@|${prefix}/bin/php|" ${worksrcpath}/${cap_name}/Util/PHP.php
reinplace "s|#!/usr/bin/env php|#!${prefix}/bin/php|" ${worksrcpath}/${real_name}.php
xinstall -m 755 ${worksrcpath}/${real_name}.php ${destroot}${prefix}/bin/${real_name}
xinstall -d ${destroot}${prefix}/lib/php
file copy ${worksrcpath}/${cap_name} ${destroot}${prefix}/lib/php/${cap_name}
set docdir ${destroot}${prefix}/share/doc/${name}
xinstall -m 644 -W ${worksrcpath} README.md ${docdir}
livecheck.url ${homepage}/tags
livecheck.regex archive/(\[0-9.\]+)\\.tar