summaryrefslogtreecommitdiffstats
path: root/php-phpspec-prophecy.spec
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2020-12-21 08:49:17 +0100
committerRemi Collet <remi@remirepo.net>2020-12-21 08:49:17 +0100
commit88202115379ed569f5be0416fcc96f5593ad097f (patch)
tree492f114e6d0b5af55f633a50c9374425312d5505 /php-phpspec-prophecy.spec
parent46b3bc9f90cdad625d652ebb7171ea51dc855bf6 (diff)
update to 1.12.2
switch to phpunit9
Diffstat (limited to 'php-phpspec-prophecy.spec')
-rw-r--r--php-phpspec-prophecy.spec28
1 files changed, 19 insertions, 9 deletions
diff --git a/php-phpspec-prophecy.spec b/php-phpspec-prophecy.spec
index a6574bc..24dec2b 100644
--- a/php-phpspec-prophecy.spec
+++ b/php-phpspec-prophecy.spec
@@ -7,7 +7,7 @@
# Please, preserve the changelog entries
#
%global bootstrap 0
-%global gh_commit 8ce87516be71aae9b956f81906aaf0338e0d8a2d
+%global gh_commit 245710e971a030f42e08f4912863805570f23d39
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner phpspec
%global gh_project prophecy
@@ -19,7 +19,7 @@
%endif
Name: php-phpspec-prophecy
-Version: 1.12.1
+Version: 1.12.2
Release: 1%{?dist}
Summary: Highly opinionated mocking framework for PHP
@@ -46,9 +46,14 @@ BuildRequires: php-doctrine-instantiator >= 1.2
%endif
# from composer.json, "require-dev": {
# "phpspec/phpspec": "^6.0"
-# "phpunit/phpunit": "^8.0 || ^9.0 <9.3"
+# "phpunit/phpunit": "^8.0 || ^9.0"
BuildRequires: php-composer(phpspec/phpspec) >= 6.0
-BuildRequires: phpunit8
+%if 0%{?fedora} >= 32 || 0%{?rhel} >=9
+%global phpunit %{_bindir}/phpunit9
+%else
+%global phpunit %{_bindir}/phpunit8
+%endif
+BuildRequires: %{phpunit}
%endif
# Autoloader
BuildRequires: php-fedora-autoloader-devel
@@ -144,13 +149,14 @@ php %{buildroot}%{_datadir}/php/Prophecy/autoload.php
phpspec --version
ret=0
-for cmd in php php72 php73 php74; do
- if which $cmd; then
- $cmd -d auto_prepend_file=vendor/autoload.php \
+for cmdarg in "php %{phpunit}" "php72 %{_bindir}/phpunit8" php73 php74 php80; do
+ if which $cmdarg; then
+ set $cmdarg
+ $1 -d auto_prepend_file=vendor/autoload.php \
%{_bindir}/phpspec run --format pretty --verbose --no-ansi || ret=1
- $cmd -d auto_prepend_file=vendor/autoload.php \
- %{_bindir}/phpunit8 || ret=1
+ $1 -d auto_prepend_file=vendor/autoload.php \
+ ${2:-%{_bindir}/phpunit9}|| ret=1
fi
done
exit $ret
@@ -169,6 +175,10 @@ exit $ret
%changelog
+* Mon Dec 21 2020 Remi Collet <remi@remirepo.net> - 1.12.2-1
+- update to 1.12.2
+- switch to phpunit9
+
* Tue Sep 29 2020 Remi Collet <remi@remirepo.net> - 1.12.1-1
- update to 1.12.1