summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer.json12
-rw-r--r--php-nyholm-psr7.spec40
2 files changed, 30 insertions, 22 deletions
diff --git a/composer.json b/composer.json
index d4c2f59..a5b9dc0 100644
--- a/composer.json
+++ b/composer.json
@@ -3,7 +3,7 @@
"description": "A fast PHP7 implementation of PSR-7",
"license": "MIT",
"keywords": ["psr-7", "psr-17"],
- "homepage": "http://tnyholm.se",
+ "homepage": "https://tnyholm.se",
"authors": [
{
"name": "Tobias Nyholm",
@@ -15,15 +15,15 @@
}
],
"require": {
- "php": "^7.1",
+ "php": ">=7.1",
"psr/http-message": "^1.0",
"php-http/message-factory": "^1.0",
"psr/http-factory": "^1.0"
},
"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"
},
"provide": {
@@ -40,10 +40,6 @@
"Tests\\Nyholm\\Psr7\\": "tests/"
}
},
- "scripts": {
- "test": "vendor/bin/phpunit",
- "test-ci": "vendor/bin/phpunit --coverage-text --coverage-clover=build/coverage.xml"
- },
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
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 <remi@remirepo.net> - 1.3.2-1
+- update to 1.3.2
+- switch to phpunit9
+
* Mon May 25 2020 Remi Collet <remi@remirepo.net> - 1.3.0-1
- update to 1.3.0