(cherry picked from commit e45af72de8)
This commit is contained in:
Remi Collet 2024-03-12 07:46:33 +01:00
commit 19924dcaa2
4 changed files with 44 additions and 11 deletions

1
.gitignore vendored
View file

@ -18,3 +18,4 @@
/phpunit10-10.5.9-0bd6637.tgz
/phpunit10-10.5.10-50b8e31.tgz
/phpunit10-10.5.11-0d968f6.tgz
/phpunit10-10.5.12-41a9886.tgz

View file

@ -1,6 +1,6 @@
diff -up ./phpunit.rpm ./phpunit
--- ./phpunit.rpm 2024-01-15 07:31:36.850034357 +0100
+++ ./phpunit 2024-01-15 07:33:02.306130486 +0100
--- ./phpunit.rpm 2024-02-26 09:36:05.000000000 +0100
+++ ./phpunit 2024-03-06 10:22:28.176494758 +0100
@@ -46,27 +46,13 @@ if (isset($GLOBALS['_composer_autoload_p
define('PHPUNIT_COMPOSER_INSTALL', $GLOBALS['_composer_autoload_path']);
@ -49,10 +49,38 @@ diff -up ./phpunit.rpm ./phpunit
+ // PHPUnit v6 to v9
+ PHPUnit\TextUI\Command::main();
+}
diff -up ./src/TextUI/Command/Commands/VersionCheckCommand.php.rpm ./src/TextUI/Command/Commands/VersionCheckCommand.php
--- ./src/TextUI/Command/Commands/VersionCheckCommand.php.rpm 2024-03-06 10:23:20.003477445 +0100
+++ ./src/TextUI/Command/Commands/VersionCheckCommand.php 2024-03-06 10:24:42.157620333 +0100
@@ -24,7 +24,7 @@ final class VersionCheckCommand implemen
public function execute(): Result
{
$latestVersion = file_get_contents('https://phar.phpunit.de/latest-version-of/phpunit');
- $latestCompatibleVersion = file_get_contents('https://phar.phpunit.de/latest-version-of/phpunit-' . Version::majorVersionNumber());
+ $latestCompatibleVersion = file_get_contents('https://phar.phpunit.de/latest-version-of/phpunit-' . $major=Version::majorVersionNumber());
$notLatest = version_compare($latestVersion, Version::id(), '>');
$notLatestCompatible = version_compare($latestCompatibleVersion, Version::id(), '>');
@@ -43,6 +43,7 @@ final class VersionCheckCommand implemen
Version::id(),
$latestCompatibleVersion,
);
+ $buffer .= sprintf('Try a system update for new phpunit%s package.' . PHP_EOL, $major);
}
if ($notLatest) {
@@ -50,6 +51,7 @@ final class VersionCheckCommand implemen
'The latest version is PHPUnit %s.' . PHP_EOL,
$latestVersion,
);
+ $buffer .= sprintf('Try to install and use the phpunit%s command.' . PHP_EOL, explode('.', $latestVersion)[0]);
}
return Result::from($buffer);
diff -up ./src/TextUI/Configuration/Xml/SchemaFinder.php.rpm ./src/TextUI/Configuration/Xml/SchemaFinder.php
--- ./src/TextUI/Configuration/Xml/SchemaFinder.php.rpm 2024-01-15 07:25:40.000000000 +0100
+++ ./src/TextUI/Configuration/Xml/SchemaFinder.php 2024-01-15 07:31:36.850034357 +0100
@@ -48,6 +48,6 @@ final class SchemaFinder
--- ./src/TextUI/Configuration/Xml/SchemaFinder.php.rpm 2024-02-26 09:36:05.000000000 +0100
+++ ./src/TextUI/Configuration/Xml/SchemaFinder.php 2024-03-06 10:22:28.177494796 +0100
@@ -75,6 +75,6 @@ final class SchemaFinder
return __PHPUNIT_PHAR_ROOT__ . '/';
}
@ -61,8 +89,8 @@ diff -up ./src/TextUI/Configuration/Xml/SchemaFinder.php.rpm ./src/TextUI/Config
}
}
diff -up ./tests/bootstrap.php.rpm ./tests/bootstrap.php
--- ./tests/bootstrap.php.rpm 2024-01-15 07:25:39.000000000 +0100
+++ ./tests/bootstrap.php 2024-01-15 07:31:36.851034393 +0100
--- ./tests/bootstrap.php.rpm 2024-02-26 09:36:05.000000000 +0100
+++ ./tests/bootstrap.php 2024-03-06 10:22:28.177494796 +0100
@@ -11,8 +11,8 @@ if (!defined('TEST_FILES_PATH')) {
define('TEST_FILES_PATH', __DIR__ . DIRECTORY_SEPARATOR . '_files' . DIRECTORY_SEPARATOR);
}

View file

@ -17,8 +17,8 @@
%bcond_with defcmd
%endif
%global gh_commit 0d968f6323deb3dbfeba5bfd4929b9415eb7a9a4
%global gh_date 2024-02-25
%global gh_commit 41a9886b85ac7bf3929853baf96b95361cd69d2b
%global gh_date 2024-03-09
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner sebastianbergmann
%global gh_project phpunit
@ -31,7 +31,7 @@
%global ver_major 10
%global ver_minor 5
%global upstream_version 10.5.11
%global upstream_version 10.5.12
#global upstream_prever dev
Name: %{pk_project}%{ver_major}
@ -41,6 +41,7 @@ Summary: The PHP Unit Testing framework version %{ver_major}
License: BSD-3-Clause
URL: https://github.com/%{gh_owner}/%{gh_project}
# run makesrc.sh to create a git snapshot with test suite
Source0: %{name}-%{upstream_version}-%{gh_short}.tgz
Source1: makesrc.sh
@ -269,6 +270,9 @@ exit $ret
%changelog
* Sat Mar 9 2024 Remi Collet <remi@remirepo.net> - 10.5.12-1
- update to 10.5.12
* Mon Feb 26 2024 Remi Collet <remi@remirepo.net> - 10.5.11-1
- update to 10.5.11

View file

@ -1 +1 @@
SHA512 (phpunit10-10.5.11-0d968f6.tgz) = 22c0f7a028e4b1d88b9217924238fd0900a365689669bb192a5b2fc7918d4d66a065f800606e56fef455810bc151d425073d4b0e213433bdbece70d3c421075d
SHA512 (phpunit10-10.5.12-41a9886.tgz) = 082dedf29edbad2ad803a8baa56500a5b0eb9ddd565e8481aa929bea09aef094003f3698570e51ec84276728d0bd24060663cf7d412433d18345070259b92855