From 631dfbb4da69fc7c8524feb7e2a566ab2703fe08 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Sep 20 2017 07:10:28 +0000 Subject: Update to 3.1.0 use phpunit6 on F26+ --- diff --git a/.gitignore b/.gitignore index 2436fea..95275c1 100644 --- a/.gitignore +++ b/.gitignore @@ -18,3 +18,4 @@ clog /PHP_CodeSniffer-3.0.0.tgz /PHP_CodeSniffer-3.0.1.tgz /PHP_CodeSniffer-3.0.2.tgz +/PHP_CodeSniffer-3.1.0.tgz diff --git a/php-pear-PHP-CodeSniffer.spec b/php-pear-PHP-CodeSniffer.spec index 3df829e..4b47167 100644 --- a/php-pear-PHP-CodeSniffer.spec +++ b/php-pear-PHP-CodeSniffer.spec @@ -13,7 +13,7 @@ %global pear_name PHP_CodeSniffer Name: php-pear-PHP-CodeSniffer -Version: 3.0.2 +Version: 3.1.0 Release: 1%{?dist} Summary: PHP coding standards enforcement tool @@ -26,7 +26,12 @@ BuildArch: noarch BuildRequires: php(language) >= 5.4 BuildRequires: php-pear # to run test suite -BuildRequires: php-phpunit-PHPUnit +%if 0%{?fedora} >= 26 +%global phpunit %{_bindir}/phpunit6 +%else +%global phpunit %{_bindir}/phpunit +%endif +BuildRequires: %{phpunit} Requires(post): %{__pear} Requires(postun): %{__pear} @@ -84,14 +89,15 @@ install -pm 644 %{pear_name}.xml %{buildroot}%{pear_xmldir} %check -cd %{pear_name}-%{version}/tests +cd %{pear_name}-%{version} -# Version 3.0.1: Tests: 238, Assertions: 86, Skipped: 3. +# Version 3.1.0: Tests: 242, Assertions: 88, Skipped: 3. ret=0 -for cmd in php php56 php70 php71 php72; do - if which $cmd; then - $cmd %{_bindir}/phpunit AllTests.php || ret=1 - fi +for cmdarg in "php %{phpunit}" "php56 %{_bindir}/phpunit" php70 php71 php72; do + if which $cmdarg; then + set $cmdarg + $1 ${2:-%{_bindir}/phpunit6} --verbose || ret=1 + fi done exit $ret @@ -118,6 +124,10 @@ fi %changelog +* Wed Sep 20 2017 Remi Collet - 3.1.0-1 +- Update to 3.1.0 +- use phpunit6 on F26+ + * Tue Jul 18 2017 Remi Collet - 3.0.2-1 - Update to 3.0.2 diff --git a/sources b/sources index d7ba1e0..182a613 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (PHP_CodeSniffer-3.0.2.tgz) = ff32e6e88be1927a662f2d1d453f9c071220e168007ccc3ec7cfd3e766ea68ea0c69d537aa37ddb75d103792d1877e0af2d4710f8f6c6d4e957f0d4c482db68c +SHA512 (PHP_CodeSniffer-3.1.0.tgz) = 8e99a845235ed288035f0941fa5c4ef60809cf55f8c4fdcb0f84682bb4592e45b4c98ef63a1abb183b7a60dc45adbb812015b68cfe038f103e8d29db2f1a3c67