From 6fbcf6f17f10de18c777b3bf5f00a484e8b39c1a Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 21 Feb 2018 08:48:44 +0100 Subject: Update to 3.2.3 use phpunit7 on F28+ --- php-pear-PHP-CodeSniffer.spec | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/php-pear-PHP-CodeSniffer.spec b/php-pear-PHP-CodeSniffer.spec index c991071..18e63cf 100644 --- a/php-pear-PHP-CodeSniffer.spec +++ b/php-pear-PHP-CodeSniffer.spec @@ -1,6 +1,6 @@ # spec file for php-pear-PHP-CodeSniffer # -# Copyright (c) 2013-2017 Remi Collet +# Copyright (c) 2013-2018 Remi Collet # Copyright (c) 2009-2013 Christof Damian # Copyright (c) 2006-2009 Konstantin Ryabitsev # @@ -13,11 +13,10 @@ %global pear_name PHP_CodeSniffer Name: php-pear-PHP-CodeSniffer -Version: 3.2.2 +Version: 3.2.3 Release: 1%{?dist} Summary: PHP coding standards enforcement tool -Group: Development/Tools License: BSD URL: http://pear.php.net/package/PHP_CodeSniffer Source0: http://pear.php.net/get/%{pear_name}-%{version}.tgz @@ -26,11 +25,17 @@ BuildArch: noarch BuildRequires: php(language) >= 5.4 BuildRequires: php-pear # to run test suite +%if 0%{?fedora} >= 28 +%global phpunit %{_bindir}/phpunit7 +%else +# remirepo:1 %if 0%{?fedora} >= 26 %global phpunit %{_bindir}/phpunit6 +# remirepo:3 %else %global phpunit %{_bindir}/phpunit %endif +%endif BuildRequires: %{phpunit} Requires(post): %{__pear} @@ -91,12 +96,12 @@ install -pm 644 %{pear_name}.xml %{buildroot}%{pear_xmldir} %check cd %{pear_name}-%{version} -# Version 3.1.0: Tests: 242, Assertions: 88, Skipped: 3. +# Version 3.2.3: Tests: 294, Assertions: 320, Skipped: 3. ret=0 -for cmdarg in "php %{phpunit}" "php56 %{_bindir}/phpunit" php70 php71 php72; do +for cmdarg in "php %{phpunit}" "php70 %{_bindir}/phpunit6" php71 php72; do if which $cmdarg; then set $cmdarg - $1 ${2:-%{_bindir}/phpunit6} --verbose || ret=1 + $1 -d memory_limit=1G ${2:-%{_bindir}/phpunit7} --verbose || ret=1 fi done exit $ret @@ -124,6 +129,10 @@ fi %changelog +* Wed Feb 21 2018 Remi Collet - 3.2.3-1 +- Update to 3.2.3 +- use phpunit7 on F28+ + * Wed Dec 20 2017 Remi Collet - 3.2.2-1 - Update to 3.2.2 -- cgit