diff --git a/.gitignore b/.gitignore index de7e88f..eed40fe 100644 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,14 @@ /phpunit9-9.5.5-89ff45e.tgz /phpunit9-9.5.6-fb9b833.tgz /phpunit9-9.5.7-d0dc8b6.tgz +/phpunit9-9.5.8-191768c.tgz +/phpunit9-9.5.9-ea8c2df.tgz +/phpunit9-9.5.10-c814a05.tgz +/phpunit9-9.5.11-2406855.tgz +/phpunit9-9.5.12-93d4bf4.tgz +/phpunit9-9.5.13-597cb64.tgz +/phpunit9-9.5.14-1883687.tgz +/phpunit9-9.5.15-dc73838.tgz +/phpunit9-9.5.16-5ff8c54.tgz +/phpunit9-9.5.17-5c5abcf.tgz +/phpunit9-9.5.18-1b58560.tgz diff --git a/phpunit9-rpm.patch b/phpunit9-rpm.patch index d3c313b..0360db7 100644 --- a/phpunit9-rpm.patch +++ b/phpunit9-rpm.patch @@ -1,19 +1,24 @@ diff -up ./phpunit.rpm ./phpunit ---- ./phpunit.rpm 2021-06-07 07:17:56.000000000 +0200 -+++ ./phpunit 2021-06-07 07:18:25.769837276 +0200 -@@ -27,25 +27,12 @@ if (!ini_get('date.timezone')) { - ini_set('date.timezone', 'UTC'); - } +--- ./phpunit.rpm 2021-12-30 09:04:15.000000000 +0100 ++++ ./phpunit 2021-12-30 09:05:07.774778660 +0100 +@@ -62,27 +62,11 @@ if (isset($GLOBALS['_composer_autoload_p + define('PHPUNIT_COMPOSER_INSTALL', $GLOBALS['_composer_autoload_path']); --foreach (array(__DIR__ . '/../../autoload.php', __DIR__ . '/../vendor/autoload.php', __DIR__ . '/vendor/autoload.php') as $file) { -- if (file_exists($file)) { -- define('PHPUNIT_COMPOSER_INSTALL', $file); + unset($GLOBALS['_composer_autoload_path']); ++} else if (file_exists('./vendor/phpunit/phpunit/phpunit') && file_exists('./vendor/autoload.php')) { ++ echo "\n==== Redirecting to composer installed version in vendor/phpunit ====\n\n"; ++ define ('PHPUNIT_COMPOSER_INSTALL', realpath('./vendor/autoload.php')); + } else { +- foreach (array(__DIR__ . '/../../autoload.php', __DIR__ . '/../vendor/autoload.php', __DIR__ . '/vendor/autoload.php') as $file) { +- if (file_exists($file)) { +- define('PHPUNIT_COMPOSER_INSTALL', $file); - -- break; +- break; +- } - } --} - --unset($file); +- unset($file); +-} - -if (!defined('PHPUNIT_COMPOSER_INSTALL')) { - fwrite( @@ -24,16 +29,11 @@ diff -up ./phpunit.rpm ./phpunit - ); - - die(1); -+// Libraries PATH -+if (file_exists('./vendor/phpunit/phpunit/phpunit') && file_exists('./vendor/autoload.php')) { -+ echo "\n==== Redirecting to composer installed version in vendor/phpunit ====\n\n"; -+ define ('PHPUNIT_COMPOSER_INSTALL', realpath('./vendor/autoload.php')); -+} else { + define ('PHPUNIT_COMPOSER_INSTALL', '/usr/share/php/PHPUnit9/autoload.php'); } $options = getopt('', array('prepend:')); -@@ -58,4 +45,8 @@ unset($options); +@@ -95,4 +79,8 @@ unset($options); require PHPUNIT_COMPOSER_INSTALL; @@ -44,8 +44,8 @@ diff -up ./phpunit.rpm ./phpunit + PHPUnit\TextUI\Command::main(); // PHPUnit v6 or newer +} diff -up ./src/Util/Xml/SchemaFinder.php.rpm ./src/Util/Xml/SchemaFinder.php ---- ./src/Util/Xml/SchemaFinder.php.rpm 2021-06-07 07:17:56.000000000 +0200 -+++ ./src/Util/Xml/SchemaFinder.php 2021-06-07 07:18:25.769837276 +0200 +--- ./src/Util/Xml/SchemaFinder.php.rpm 2021-12-30 09:04:15.000000000 +0100 ++++ ./src/Util/Xml/SchemaFinder.php 2021-12-30 09:04:21.186910890 +0100 @@ -48,6 +48,6 @@ final class SchemaFinder return __PHPUNIT_PHAR_ROOT__ . '/'; } @@ -55,22 +55,33 @@ diff -up ./src/Util/Xml/SchemaFinder.php.rpm ./src/Util/Xml/SchemaFinder.php } } diff -up ./tests/bootstrap.php.rpm ./tests/bootstrap.php ---- ./tests/bootstrap.php.rpm 2021-06-07 07:18:25.769837276 +0200 -+++ ./tests/bootstrap.php 2021-06-07 07:19:32.888583752 +0200 -@@ -8,7 +8,7 @@ - * file that was distributed with this source code. +--- ./tests/bootstrap.php.rpm 2021-12-30 09:04:15.000000000 +0100 ++++ ./tests/bootstrap.php 2021-12-30 09:04:21.186910890 +0100 +@@ -9,8 +9,8 @@ */ - if (!defined('PHPUNIT_COMPOSER_INSTALL')) { -- define('PHPUNIT_COMPOSER_INSTALL', dirname(__DIR__) . '/vendor/autoload.php'); -+ define('PHPUNIT_COMPOSER_INSTALL', '@PATH@/autoload.php'); + const TEST_FILES_PATH = __DIR__ . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR; + +-$composer = file_exists(__DIR__ . '/../vendor/autoload.php'); +-$phar = file_exists(__DIR__ . '/autoload.php'); ++$composer = true; ++$phar = false; + + if ($composer && $phar) { + print 'More than one test fixture autoloader is available, exiting.' . PHP_EOL; +@@ -26,10 +26,14 @@ if (!$composer && !$phar) { + + if ($composer) { + if (!defined('PHPUNIT_COMPOSER_INSTALL')) { +- define('PHPUNIT_COMPOSER_INSTALL', dirname(__DIR__) . '/vendor/autoload.php'); ++ define('PHPUNIT_COMPOSER_INSTALL', '@PATH@/autoload.php'); + } + +- require_once __DIR__ . '/../vendor/autoload.php'; ++ require_once PHPUNIT_COMPOSER_INSTALL; ++ require_once __DIR__ . '/_files/CoverageNamespacedFunctionTest.php'; ++ require_once __DIR__ . '/_files/CoveredFunction.php'; ++ require_once __DIR__ . '/_files/NamespaceCoveredFunction.php'; ++ require_once __DIR__ . '/autoload.php'; } - if (!defined('TEST_FILES_PATH')) { -@@ -19,3 +19,7 @@ ini_set('precision', '14'); - ini_set('serialize_precision', '14'); - - require_once PHPUNIT_COMPOSER_INSTALL; -+require_once __DIR__ . '/_files/CoverageNamespacedFunctionTest.php'; -+require_once __DIR__ . '/_files/CoveredFunction.php'; -+require_once __DIR__ . '/_files/NamespaceCoveredFunction.php'; -+require_once __DIR__ . '/autoload.php'; + if ($phar) { diff --git a/phpunit9.spec b/phpunit9.spec index 9e06418..fcafff4 100644 --- a/phpunit9.spec +++ b/phpunit9.spec @@ -1,6 +1,6 @@ # remirepo/fedora spec file for phpunit9 # -# Copyright (c) 2010-2021 Remi Collet +# Copyright (c) 2010-2022 Remi Collet # # License: CC-BY-SA # http://creativecommons.org/licenses/by-sa/4.0/ @@ -11,7 +11,7 @@ # For compatibility with SCL %undefine __brp_mangle_shebangs -%global gh_commit d0dc8b6999c937616df4fb046792004b33fd31c5 +%global gh_commit 1b5856028273bfd855e60a887278857d872ec67a #global gh_date 20150927 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) %global gh_owner sebastianbergmann @@ -25,7 +25,7 @@ %global ver_major 9 %global ver_minor 5 -%global upstream_version 9.5.7 +%global upstream_version 9.5.18 #global upstream_prever dev Name: %{pk_project}%{ver_major} @@ -34,7 +34,7 @@ Release: 1%{?dist} Summary: The PHP Unit Testing framework version %{ver_major} License: BSD -URL: https://github.com/%{gh_vendor}/%{gh_project} +URL: https://github.com/%{gh_owner}/%{gh_project} Source0: %{name}-%{upstream_version}-%{gh_short}.tgz Source1: makesrc.sh @@ -45,10 +45,10 @@ BuildArch: noarch BuildRequires: php(language) >= 7.3 BuildRequires: (php-composer(doctrine/instantiator) >= 1.3.1 with php-composer(doctrine/instantiator) < 2) BuildRequires: (php-composer(myclabs/deep-copy) >= 1.10.1 with php-composer(myclabs/deep-copy) < 2) -BuildRequires: (php-composer(phar-io/manifest) >= 2.0.1 with php-composer(phar-io/manifest) < 3) +BuildRequires: (php-composer(phar-io/manifest) >= 2.0.3 with php-composer(phar-io/manifest) < 3) BuildRequires: (php-composer(phar-io/version) >= 3.0.2 with php-composer(phar-io/version) < 4) BuildRequires: (php-composer(phpspec/prophecy) >= 1.12.1 with php-composer(phpspec/prophecy) < 2) -BuildRequires: (php-composer(phpunit/php-code-coverage) >= 9.2.3 with php-composer(phpunit/php-code-coverage) < 10) +BuildRequires: (php-composer(phpunit/php-code-coverage) >= 9.2.13 with php-composer(phpunit/php-code-coverage) < 10) BuildRequires: (php-composer(phpunit/php-file-iterator) >= 3.0.4 with php-composer(phpunit/php-file-iterator) < 4) BuildRequires: (php-composer(phpunit/php-invoker) >= 3.1 with php-composer(phpunit/php-invoker) < 4) BuildRequires: (php-composer(phpunit/php-text-template) >= 2.0.2 with php-composer(phpunit/php-text-template) < 3) @@ -83,10 +83,10 @@ BuildRequires: php-fedora-autoloader-devel >= 1.0.0 # "ext-xmlwriter": "*", # "doctrine/instantiator": "^1.3.1", # "myclabs/deep-copy": "^1.10.1", -# "phar-io/manifest": "^2.0.1", +# "phar-io/manifest": "^2.0.3", # "phar-io/version": "^3.0.2", # "phpspec/prophecy": "^1.12.1", -# "phpunit/php-code-coverage": "^9.2.3", +# "phpunit/php-code-coverage": "^9.2.13", # "phpunit/php-file-iterator": "^3.0.5", # "phpunit/php-invoker": "^3.1.1", # "phpunit/php-text-template": "^2.0.3", @@ -112,10 +112,10 @@ Requires: php-xml Requires: php-xmlwriter Requires: (php-composer(doctrine/instantiator) >= 1.3.1 with php-composer(doctrine/instantiator) < 2) Requires: (php-composer(myclabs/deep-copy) >= 1.10.1 with php-composer(myclabs/deep-copy) < 2) -Requires: (php-composer(phar-io/manifest) >= 2.0.1 with php-composer(phar-io/manifest) < 3) +Requires: (php-composer(phar-io/manifest) >= 2.0.3 with php-composer(phar-io/manifest) < 3) Requires: (php-composer(phar-io/version) >= 3.0.2 with php-composer(phar-io/version) < 4) Requires: (php-composer(phpspec/prophecy) >= 1.12.1 with php-composer(phpspec/prophecy) < 2) -Requires: (php-composer(phpunit/php-code-coverage) >= 9.2.3 with php-composer(phpunit/php-code-coverage) < 10) +Requires: (php-composer(phpunit/php-code-coverage) >= 9.2.13 with php-composer(phpunit/php-code-coverage) < 10) Requires: (php-composer(phpunit/php-file-iterator) >= 3.0.4 with php-composer(phpunit/php-file-iterator) < 4) Requires: (php-composer(phpunit/php-invoker) >= 3.1 with php-composer(phpunit/php-invoker) < 4) Requires: (php-composer(phpunit/php-text-template) >= 2.0.2 with php-composer(phpunit/php-text-template) < 3) @@ -232,7 +232,7 @@ sed -e 's:@PATH@:%{buildroot}%{php_home}/%{ns_vendor}:' -i tests/bootstrap.php sed -e 's:%{php_home}/%{ns_vendor}:%{buildroot}%{php_home}/%{ns_vendor}:' -i phpunit ret=0 -for cmd in php php73 php74 php80; do +for cmd in php php74 php80 php81; do if which $cmd; then $cmd ./phpunit $OPT --verbose || ret=1 fi @@ -249,6 +249,43 @@ exit $ret %changelog +* Tue Mar 8 2022 Remi Collet - 9.5.18-1 +- update to 9.5.18 + +* Sun Mar 6 2022 Remi Collet - 9.5.17-1 +- update to 9.5.17 #StandWithUkraine + +* Thu Feb 24 2022 Remi Collet - 9.5.16-1 +- update to 9.5.16 +- raise dependency on phpunit/php-code-coverage 9.2.13 + +* Wed Feb 23 2022 Remi Collet - 9.5.15-1 +- update to 9.5.15 +- raise dependency on phpunit/php-code-coverage 9.2.12 + +* Fri Feb 18 2022 Remi Collet - 9.5.14-1 +- update to 9.5.14 + +* Mon Jan 24 2022 Remi Collet - 9.5.13-1 +- update to 9.5.13 + +* Fri Jan 21 2022 Remi Collet - 9.5.12-1 +- update to 9.5.12 + +* Thu Dec 30 2021 Remi Collet - 9.5.11-1 +- update to 9.5.11 + +* Mon Sep 27 2021 Remi Collet - 9.5.10-1 +- update to 9.5.10 +- raise dependency on phpunit/php-code-coverage 9.2.7 + +* Wed Sep 1 2021 Remi Collet - 9.5.9-1 +- update to 9.5.9 + +* Mon Aug 2 2021 Remi Collet - 9.5.8-1 +- update to 9.5.8 +- raise dependency on phar-io/manifest 2.0.3 + * Mon Jul 19 2021 Remi Collet - 9.5.7-1 - update to 9.5.7 diff --git a/sources b/sources index e3379b3..c759b02 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (phpunit9-9.5.7-d0dc8b6.tgz) = 9905b3c4af10015c28c125b2a0f90556912f322b96e3edbd6ba7c7f94cf84857615dffe6177deca77342a7a95487df4a8bc9814aa56f8e16bdf67ff01299c891 +SHA512 (phpunit9-9.5.18-1b58560.tgz) = 716d4bc42de9c311564621dee89faefee16666ddc564a73dc8a8d84d10038cf5b520312f97de43c34699febe1a0bc4e0bac71d2dcc40522763b605f474851901