From d4ae1f193913c974af0c4c6313b473cbc49f2734 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 16 Nov 2020 10:18:01 +0100 Subject: update to 1.3.2 switch to phpunit9 --- php-nyholm-psr7.spec | 40 ++++++++++++++++++++++++++-------------- 1 file changed, 26 insertions(+), 14 deletions(-) (limited to 'php-nyholm-psr7.spec') diff --git a/php-nyholm-psr7.spec b/php-nyholm-psr7.spec index c0c4885..45da353 100644 --- a/php-nyholm-psr7.spec +++ b/php-nyholm-psr7.spec @@ -8,7 +8,7 @@ # %global bootstrap 0 # github -%global gh_commit c17f4f73985f62054a331cbc4ffdf9868c4ef256 +%global gh_commit a272953743c454ac4af9626634daaf5ab3ce1173 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner Nyholm %global gh_project psr7 @@ -26,15 +26,15 @@ %global with_tests 0%{!?_without_tests:1} %endif -# php-http/psr7-integration-tests -%global psr7_integration_tests_commit c3bb79ca4a276df57364ff45bf2f619f769ded4a +# php-http/psr7-integration-tests 1.1.0 +%global psr7_integration_tests_commit b63c2f50c114a474086c6801aea58c0aa96f9b27 %global psr7_integration_tests_short %(c=%{psr7_integration_tests_commit}; echo ${c:0:7}) -# http-interop/http-factory-tests -%global http_factory_tests_commit 92d8b91e7236957d7512ef93e8a237d241671ce7 +# http-interop/http-factory-tests 0.8.0 +%global http_factory_tests_commit 7384d93cd4841647b16b3c9bfd56c0367a40fce1 %global http_factory_tests_short %(c=%{http_factory_tests_commit}; echo ${c:0:7}) Name: php-%{pk_vendor}-%{pk_project}%{major} -Version: 1.3.0 +Version: 1.3.2 Release: 1%{?dist} Summary: A fast PHP7 implementation of PSR-7 @@ -68,15 +68,21 @@ BuildRequires: php-symfony4-error-handler >= 4.4 BuildRequires: php-fedora-autoloader-devel >= 1.0.0 %if %{with_tests} # from composer.json, "require-dev": { -# "phpunit/phpunit": "^7.5", +# "phpunit/phpunit": "^7.5 || 8.5 || 9.4", # "php-http/psr7-integration-tests": "^1.0", -# "http-interop/http-factory-tests": "dev-master", +# "http-interop/http-factory-tests": "^0.8", # "symfony/error-handler": "^4.4" -BuildRequires: phpunit7 > 7.5 +%if 0%{?fedora} >= 32 || 0%{?rhel} >= 9 +%global phpunit %{_bindir}/phpunit9 +BuildRequires: phpunit9 >= 9.4 +%else +%global phpunit %{_bindir}/phpunit9 +BuildRequires: phpunit8 >= 8.5 +%endif %endif # from composer.json, "require": { -# "php": "^7.1", +# "php": ">=7.1", # "psr/http-message": "^1.0", # "php-http/message-factory": "^1.0", # "psr/http-factory": "^1.0" @@ -149,11 +155,13 @@ EOF : Run upstream test suite : Ignore online tests # TODO testCanDetachStream may fail on local build (extension conflicts ?) +# testIsNotSeekable|testIsNotWritable|testIsNotReadable|testRewindNotSeekable fail only in mock ret=0 -for cmd in php php71 php72 php73 php74; do - if which $cmd; then - $cmd %{_bindir}/phpunit7 \ - --filter '^((?!(testIsNotSeekable|testIsNotWritable|testIsNotReadable|testRewindNotSeekable)).)*$' \ +for cmdarg in "php %{phpunit}" "php72 %{_bindir}/phpunit8" php73 php74 php80; do + if which $cmdarg; then + set $cmdarg + $1 ${2:-%{_bindir}/phpunit9} \ + --filter '^((?!(testIsNotSeekable|testIsNotWritable|testIsNotReadable|testRewindNotSeekable|testCanDetachStream)).)*$' \ --verbose || ret=1 fi done @@ -173,6 +181,10 @@ exit $ret %changelog +* Mon Nov 16 2020 Remi Collet - 1.3.2-1 +- update to 1.3.2 +- switch to phpunit9 + * Mon May 25 2020 Remi Collet - 1.3.0-1 - update to 1.3.0 -- cgit