summaryrefslogtreecommitdiffstats
path: root/php-phar-io-version.spec
diff options
context:
space:
mode:
Diffstat (limited to 'php-phar-io-version.spec')
-rw-r--r--php-phar-io-version.spec25
1 files changed, 17 insertions, 8 deletions
diff --git a/php-phar-io-version.spec b/php-phar-io-version.spec
index 2158a09..2d385f8 100644
--- a/php-phar-io-version.spec
+++ b/php-phar-io-version.spec
@@ -1,6 +1,6 @@
# remirepo/fedora spec file for php-phar-io-version
#
-# Copyright (c) 2017-2018 Remi Collet
+# Copyright (c) 2017-2021 Remi Collet
# License: CC-BY-SA
# http://creativecommons.org/licenses/by-sa/4.0/
#
@@ -25,22 +25,27 @@
Name: php-%{pk_vendor}-%{pk_project}%{major}
Version: 2.0.1
-Release: 1%{?dist}
+Release: 7%{?dist}
Summary: Library for handling version information and constraints
-Group: Development/Libraries
License: BSD
URL: https://github.com/%{gh_owner}/%{gh_project}
Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{name}-%{version}-%{gh_short}.tar.gz
BuildArch: noarch
-# PHP 7 for phpunit6
-BuildRequires: php(language) >= 7
+# PHP 7.2 for phpunit8, 7.3 for phpunit9
+BuildRequires: php(language) >= 5.6
BuildRequires: php-pcre
BuildRequires: php-spl
BuildRequires: php-fedora-autoloader-devel >= 1.0.0
%if %{with_tests}
-BuildRequires: phpunit6
+%if 0%{?fedora} >= 32 || 0%{?rhel} >= 9
+%global phpunit %{_bindir}/phpunit9
+BuildRequires: phpunit9
+%else
+%global phpunit %{_bindir}/phpunit8
+BuildRequires: phpunit8
+%endif
%endif
# from composer.json
@@ -79,10 +84,10 @@ cp -pr src %{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}%{major}
%if %{with_tests}
: Run upstream test suite
ret=0
-for cmd in php php70 php71 php72 php73; do
+for cmd in php php73 php74 php80; do
if which $cmd; then
$cmd -d auto_prepend_file=%{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}%{major}/autoload.php \
- %{_bindir}/phpunit6 --bootstrap %{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}/autoload.php --verbose || ret=1
+ %{phpunit} --bootstrap %{buildroot}%{php_home}/%{ns_vendor}/%{ns_project}/autoload.php --verbose || ret=1
fi
done
exit $ret
@@ -92,6 +97,7 @@ exit $ret
%files
+# remirepo:1
%{!?_licensedir:%global license %%doc}
%license LICENSE
%doc README.md composer.json
@@ -100,6 +106,9 @@ exit $ret
%changelog
+* Wed Mar 10 2021 Remi Collet <remi@remirepo.net> - 2.0.1-7
+- switch to phpunit9
+
* Mon Jul 16 2018 Remi Collet <remi@remirepo.net> - 2.0.1-1
- update to 2.0.1