diff options
Diffstat (limited to 'php-phpunit-phpdcd.spec')
-rw-r--r-- | php-phpunit-phpdcd.spec | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/php-phpunit-phpdcd.spec b/php-phpunit-phpdcd.spec index 0817434..73c86fd 100644 --- a/php-phpunit-phpdcd.spec +++ b/php-phpunit-phpdcd.spec @@ -9,7 +9,7 @@ Name: php-phpunit-phpdcd Version: 1.0.2 -Release: 1%{?dist} +Release: 7%{?dist} Summary: Dead Code Detector (DCD) for PHP code Group: Development/Libraries @@ -23,7 +23,6 @@ Source1: Autoload.php.in # Fix for RPM, use autoload Patch0: %{gh_project}-rpm.patch -BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch BuildRequires: php(language) >= 5.3.3 BuildRequires: %{_bindir}/phpab @@ -37,6 +36,7 @@ BuildRequires: php-phpunit-PHP-TokenStream >= 1.1.3 %endif # From composer.json +# Use package names so ensure major version Requires: php(language) >= 5.3.3 Requires: php-phpunit-FinderFacade >= 1.1.0 Requires: php-phpunit-Version >= 1.0.3 @@ -68,7 +68,6 @@ phpab \ %install -rm -rf %{buildroot} mkdir -p %{buildroot}%{php_home} cp -pr src %{buildroot}%{php_home}/PHPDCD @@ -77,17 +76,16 @@ install -D -p -m 755 phpdcd %{buildroot}%{_bindir}/phpdcd %if %{with_tests} %check -phpunit \ - --bootstrap src/Autoload.php \ - -d date.timezone=UTC \ - tests +ret=0 +for cmd in php php56 php70 php71 php72; do + if which $cmd; then + $cmd %{_bindir}/phpunit --bootstrap src/Autoload.php tests || ret=1 + fi +done +exit $ret %endif -%clean -rm -rf %{buildroot} - - %post if [ -x %{_bindir}/pear ]; then %{_bindir}/pear uninstall --nodeps --ignore-errors --register-only \ @@ -96,13 +94,15 @@ fi %files -%defattr(-,root,root,-) %doc LICENSE README.md composer.json %{php_home}/PHPDCD %{_bindir}/phpdcd %changelog +* Mon Nov 6 2017 Remi Collet <remi@remirepo.net> - 1.0.2-7 +- cleanup + * Sun May 4 2014 Remi Collet <remi@fedoraproject.org> - 1.0.2-1 - update to 1.0.2 - sources from github |