diff options
-rw-r--r-- | php-theseer-directoryscanner.spec | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/php-theseer-directoryscanner.spec b/php-theseer-directoryscanner.spec index 4eaf27c..80a69ef 100644 --- a/php-theseer-directoryscanner.spec +++ b/php-theseer-directoryscanner.spec @@ -1,6 +1,6 @@ # spec file for php-theseer-directoryscanner # -# Copyright (c) 2014-2021 Remi Collet +# Copyright (c) 2014-2024 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # @@ -22,18 +22,18 @@ Name: php-theseer-directoryscanner Version: 1.3.3 -Release: 2%{?dist} +Release: 8%{?dist} Summary: A recursive directory scanner and filter Group: Development/Libraries -License: BSD +License: BSD-2-Clause URL: https://github.com/%{gh_owner}/%{gh_project} Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{name}-%{version}.tar.gz BuildArch: noarch BuildRequires: php(language) >= 5.3.1 %if %{with tests} -BuildRequires: %{_bindir}/phpunit +BuildRequires: phpunit7 %endif # From composer.json @@ -65,13 +65,21 @@ cp -pr src %{buildroot}%{php_home}/%{gh_project} %check %if %{with tests} +cat << 'EOF' | tee bs.php +<?php +require_once '%{buildroot}%{php_home}/%{gh_project}/autoload.php'; +class_alias('PHPUnit\\Framework\\TestCase', 'PHPUnit_Framework_TestCase'); +EOF + ret=0 -for cmd in php php74 php80 php81; do +for cmd in php php81 php82 php83; do if which $cmd; then - $cmd %{_bindir}/phpunit \ - --bootstrap %{buildroot}%{php_home}/%{gh_project}/autoload.php \ + $cmd %{_bindir}/phpunit7 \ + --bootstrap bs.php \ --verbose \ - --no-coverage || ret=1 + --no-coverage \ + --no-configuration \ + tests/*php|| ret=1 fi done exit $ret @@ -94,6 +102,9 @@ fi %changelog +* Wed Jan 31 2024 Remi Collet <remi@remirepo.net> - 1.3.3-8 +- use phpunit7 FTBFS #2261513 + * Mon Dec 6 2021 Remi Collet <remi@remirepo.net> - 1.3.3-2 - disable test suite on EL |