From df4c21d954b6c24f67247a0d5e2a2089493bd534 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 26 Feb 2021 17:10:09 +0100 Subject: update to 2.10.0 switch to phpunit9 --- composer.json | 15 ++++++++------- php-laminas-paginator.spec | 46 ++++++++++++++++++++++------------------------ 2 files changed, 30 insertions(+), 31 deletions(-) diff --git a/composer.json b/composer.json index 7edb008..968ec58 100644 --- a/composer.json +++ b/composer.json @@ -25,26 +25,26 @@ } }, "require": { - "php": "^7.3", + "php": "^7.3 || ~8.0.0", + "ext-json": "*", "laminas/laminas-stdlib": "^3.2.1", "laminas/laminas-zendframework-bridge": "^1.0.4" }, "require-dev": { "laminas/laminas-cache": "^2.9.0", - "laminas/laminas-coding-standard": "~1.0.0", + "laminas/laminas-coding-standard": "~2.1.4", "laminas/laminas-config": "^2.6.0", - "laminas/laminas-db": "^2.11.3", "laminas/laminas-filter": "^2.9.4", - "laminas/laminas-json": "^2.6.1", "laminas/laminas-servicemanager": "^3.4.1", "laminas/laminas-view": "^2.11.4", - "phpunit/phpunit": "^8.5.8" + "phpunit/phpunit": "^9.3", + "psalm/plugin-phpunit": "^0.15.1", + "vimeo/psalm": "^4.6" }, "suggest": { "laminas/laminas-cache": "Laminas\\Cache component to support cache features", - "laminas/laminas-db": "Laminas\\Db component", "laminas/laminas-filter": "Laminas\\Filter component", - "laminas/laminas-json": "Laminas\\Json component", + "laminas/laminas-paginator-adapter-laminasdb": "Provides pagination adapters for Select statements and TableGateway instances", "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", "laminas/laminas-view": "Laminas\\View component" }, @@ -65,6 +65,7 @@ ], "cs-check": "phpcs", "cs-fix": "phpcbf", + "static-analysis": "psalm --shepherd --stats", "test": "phpunit --colors=always", "test-coverage": "phpunit --colors=always --coverage-clover clover.xml" }, diff --git a/php-laminas-paginator.spec b/php-laminas-paginator.spec index 85dfccd..52cd4d5 100644 --- a/php-laminas-paginator.spec +++ b/php-laminas-paginator.spec @@ -1,13 +1,13 @@ # remirepo/Fedora spec file for php-laminas-paginator # -# Copyright (c) 2015-2020 Remi Collet +# Copyright (c) 2015-2021 Remi Collet # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # %global bootstrap 0 -%global gh_commit f1cf5c29d8dd7d6aa77f490e322326b3b670e28c +%global gh_commit 14ce4a397e6329954389cc40aa635caa9573f695 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner laminas %global gh_project laminas-paginator @@ -22,7 +22,7 @@ %endif Name: php-%{gh_project} -Version: 2.9.0 +Version: 2.10.0 Release: 1%{?dist} Summary: %{namespace} Framework %{library} component @@ -43,20 +43,17 @@ BuildRequires: (php-autoloader(%{gh_owner}/laminas-stdlib) >= 3.2. BuildRequires: (php-autoloader(%{gh_owner}/laminas-zendframework-bridge) >= 1.0.4 with php-autoloader(%{gh_owner}/laminas-zendframework-bridge) < 2) # From composer, "require-dev": { # "laminas/laminas-cache": "^2.9.0", -# "laminas/laminas-coding-standard": "~1.0.0", +# "laminas/laminas-coding-standard": "~2.1.4", # "laminas/laminas-config": "^2.6.0", -# "laminas/laminas-db": "^2.11.3", # "laminas/laminas-filter": "^2.9.4", -# "laminas/laminas-json": "^2.6.1", # "laminas/laminas-servicemanager": "^3.4.1", # "laminas/laminas-view": "^2.11.4", -# "phpunit/phpunit": "^8.5.8" +# "phpunit/phpunit": "^9.3", +# "psalm/plugin-phpunit": "^0.15.1", +# "vimeo/psalm": "^4.6" BuildRequires: (php-autoloader(%{gh_owner}/laminas-cache) >= 2.9.0 with php-autoloader(%{gh_owner}/laminas-cache) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-config) >= 2.6.0 with php-autoloader(%{gh_owner}/laminas-config) < 3) -BuildRequires: (php-autoloader(%{gh_owner}/laminas-db) >= 2.11.3 with php-autoloader(%{gh_owner}/laminas-db) < 3) BuildRequires: (php-autoloader(%{gh_owner}/laminas-filter) >= 2.9.4 with php-autoloader(%{gh_owner}/laminas-filter) < 3) -# ignore max version as test suite passes with 3.1.1 -BuildRequires: php-autoloader(%{gh_owner}/laminas-json) >= 2.6.1 BuildRequires: (php-autoloader(%{gh_owner}/laminas-servicemanager) >= 3.4.1 with php-autoloader(%{gh_owner}/laminas-servicemanager) < 4) BuildRequires: (php-autoloader(%{gh_owner}/laminas-view) >= 2.11.4 with php-autoloader(%{gh_owner}/laminas-view) < 3) # remirepo:11 @@ -65,22 +62,23 @@ BuildRequires: php-laminas-stdlib >= 3.2. BuildRequires: php-laminas-zendframework-bridge >= 1.0.4 BuildRequires: php-laminas-cache >= 2.9.0 BuildRequires: php-laminas-config >= 2.6.0 -BuildRequires: php-laminas-db >= 2.11.3 BuildRequires: php-laminas-filter >= 2.9.4 -BuildRequires: php-laminas-json >= 2.6.1 BuildRequires: php-laminas-servicemanager >= 3.4.1 BuildRequires: php-laminas-view >= 2.11.4 %endif -BuildRequires: phpunit8 >= 8.5.8 +%global phpunit %{_bindir}/phpunit9 +BuildRequires: phpunit9 >= 9.3 %endif # Autoloader BuildRequires: php-fedora-autoloader-devel # From composer, "require": { -# "php": "^7.3", +# "php": "^7.3 || ~8.0.0", +# "ext-json": "*", # "laminas/laminas-stdlib": "^3.2.1", # "laminas/laminas-zendframework-bridge": "^1.0.4" Requires: php(language) >= 7.3 +Requires: php-json %if ! %{bootstrap} # remirepo:1 %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8 @@ -88,15 +86,13 @@ Requires: (php-autoloader(%{gh_owner}/laminas-stdlib) >= 3.2. Requires: (php-autoloader(%{gh_owner}/laminas-zendframework-bridge) >= 1.0.4 with php-autoloader(%{gh_owner}/laminas-zendframework-bridge) < 2) # From composer, "suggest": { # "laminas/laminas-cache": "Laminas\\Cache component to support cache features", -# "laminas/laminas-db": "Laminas\\Db component", # "laminas/laminas-filter": "Laminas\\Filter component", -# "laminas/laminas-json": "Laminas\\Json component", +# "laminas/laminas-paginator-adapter-laminasdb": "Provides pagination adapters for Select statements and TableGateway instances", # "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", # "laminas/laminas-view": "Laminas\\View component" Suggests: php-autoloader(%{gh_owner}/laminas-cache) -Suggests: php-autoloader(%{gh_owner}/laminas-db) Suggests: php-autoloader(%{gh_owner}/laminas-filter) -Suggests: php-autoloader(%{gh_owner}/laminas-json) +Suggests: php-autoloader(%{gh_owner}/laminas-paginator-adapter-laminasdb) Suggests: php-autoloader(%{gh_owner}/laminas-servicemanager) Suggests: php-autoloader(%{gh_owner}/laminas-view) # remirepo:4 @@ -108,7 +104,6 @@ Requires: php-laminas-zendframework-bridge # Autoloader Requires: php-composer(fedora/autoloader) # From phpcompatinfo report for version 2.8.2 -Requires: php-json Requires: php-spl # remirepo:2 @@ -145,9 +140,7 @@ cat << 'EOF' | tee -a src/autoload.php ]); \Fedora\Autoloader\Dependencies::optional([ '%{php_home}/%{namespace}/Cache/autoload.php', - '%{php_home}/%{namespace}/Db/autoload.php', '%{php_home}/%{namespace}/Filter/autoload.php', - '%{php_home}/%{namespace}/Json/autoload.php', '%{php_home}/%{namespace}/ServiceManager/autoload.php', '%{php_home}/%{namespace}/View/autoload.php', ]); @@ -193,9 +186,10 @@ exit (class_exists("\\Zend\\%{library}\\Factory") ? 0 : 1); : upstream test suite ret=0 -for cmd in php php72 php73 php74; do - if which $cmd; then - $cmd %{_bindir}/phpunit8 --verbose || ret=1 +for cmdarg in "php %{phpunit}" php73 php74 php80; do + if which $cmdarg; then + set $cmdarg + $1 ${2:-%{_bindir}/phpunit9} --verbose || ret=1 fi done exit $ret @@ -215,6 +209,10 @@ exit $ret %changelog +* Fri Feb 26 2021 Remi Collet - 2.10.0-1 +- update to 2.10.0 +- switch to phpunit9 + * Fri Sep 11 2020 Remi Collet - 2.9.0-1 - update to 2.9.0 - raise dependency to PHP 7.3 -- cgit