diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md
index 697216fda18..3c06020c0d1 100644
--- a/.github/CONTRIBUTING.md
+++ b/.github/CONTRIBUTING.md
@@ -18,6 +18,21 @@ Please note that this project is released with a [Contributor Code of Conduct](C
When you submit code changes, your submissions are understood to be under the same [BSD-3-Clause License](https://github.com/sebastianbergmann/phpunit/blob/main/LICENSE) that covers the project. By contributing to this project, you agree that your contributions will be licensed under its BSD-3-Clause License.
+### Do Not Violate Copyright
+
+Only submit a pull request with your own original code. Do NOT submit a pull request containing code which you have largely copied from
+another project, unless you wrote the respective code yourself.
+
+Open Source does not mean that copyright does not apply. Copyright infringements will not be tolerated and can lead to you being banned from this project and repository.
+
+### Do Not Submit AI-Generated Pull Requests
+
+The same goes for (largely) AI-generated pull requests. These are not welcome as they will be based on copyrighted code from others
+without accreditation and without taking the license of the original code into account, let alone getting permission
+for the use of the code or for re-licensing.
+
+Aside from that, the experience is that AI-generated pull requests will be incorrect 100% of the time and cost reviewers too much time.
+Submitting a (largely) AI-generated pull request will lead to you being banned from this project and repository.
## Write bug reports with detail, background, and sample code
diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml
index 16ea2ac7f40..f17263f9d86 100644
--- a/.github/workflows/ci.yaml
+++ b/.github/workflows/ci.yaml
@@ -118,6 +118,7 @@ jobs:
- "8.2"
- "8.3"
- "8.4"
+ - "8.5"
steps:
- name: Configure git to avoid issues with line endings
@@ -168,6 +169,7 @@ jobs:
- "8.2"
- "8.3"
- "8.4"
+ - "8.5"
steps:
- name: Configure git to avoid issues with line endings
@@ -208,7 +210,7 @@ jobs:
- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
with:
- php-version: 8.3
+ php-version: 8.4
coverage: xdebug
extensions: none, curl, dom, json, libxml, mbstring, phar, soap, tokenizer, xml, xmlwriter
ini-values: assert.exception=1, zend.assertions=1, error_reporting=-1, log_errors_max_len=0, display_errors=On
@@ -297,6 +299,7 @@ jobs:
- "8.2"
- "8.3"
- "8.4"
+ - "8.5"
coverage:
- pcov
diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml
index 8b2753f04dc..a388ad8ae50 100644
--- a/.github/workflows/release.yaml
+++ b/.github/workflows/release.yaml
@@ -41,6 +41,7 @@ jobs:
tag: ${{ env.RELEASE_TAG }}
name: PHPUnit ${{ env.RELEASE_TAG }}
bodyFile: release-notes.md
+ commit: "9.6"
- name: Announce release
id: mastodon
diff --git a/.phive/phars.xml b/.phive/phars.xml
index d9607a3cc73..b46defffd10 100644
--- a/.phive/phars.xml
+++ b/.phive/phars.xml
@@ -1,8 +1,8 @@
-
-
-
+
+
+
-
+
diff --git a/.php-cs-fixer.dist.php b/.php-cs-fixer.dist.php
index e046257c9a4..0973c453dba 100644
--- a/.php-cs-fixer.dist.php
+++ b/.php-cs-fixer.dist.php
@@ -156,7 +156,23 @@
'no_empty_comment' => true,
'no_empty_phpdoc' => true,
'no_empty_statement' => true,
- 'no_extra_blank_lines' => true,
+ 'no_extra_blank_lines' => [
+ 'tokens' => [
+ 'attribute',
+ 'break',
+ 'case',
+ 'continue',
+ 'curly_brace_block',
+ 'default',
+ 'extra',
+ 'parenthesis_brace_block',
+ 'return',
+ 'square_brace_block',
+ 'switch',
+ 'throw',
+ 'use',
+ ],
+ ],
'no_homoglyph_names' => true,
'no_leading_import_slash' => true,
'no_leading_namespace_whitespace' => true,
diff --git a/ChangeLog-9.6.md b/ChangeLog-9.6.md
index e6c6bc038ab..b8ce54ebc09 100644
--- a/ChangeLog-9.6.md
+++ b/ChangeLog-9.6.md
@@ -2,6 +2,12 @@
All notable changes of the PHPUnit 9.6 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles.
+## [9.6.22] - 2024-12-05
+
+### Fixed
+
+* [#6071](https://github.com/sebastianbergmann/phpunit/issues/6071): PHP Archives (PHARs) of PHPUnit 8.5 and PHPUnit 9.6 bundle outdated versions of Prophecy
+
## [9.6.21] - 2024-09-19
### Changed
@@ -156,6 +162,7 @@ All notable changes of the PHPUnit 9.6 release series are documented in this fil
* [#5064](https://github.com/sebastianbergmann/phpunit/issues/5064): Deprecate `PHPUnit\Framework\TestCase::getMockClass()`
* [#5132](https://github.com/sebastianbergmann/phpunit/issues/5132): Deprecate `Test` suffix for abstract test case classes
+[9.6.22]: https://github.com/sebastianbergmann/phpunit/compare/9.6.21...9.6.22
[9.6.21]: https://github.com/sebastianbergmann/phpunit/compare/9.6.20...9.6.21
[9.6.20]: https://github.com/sebastianbergmann/phpunit/compare/9.6.19...9.6.20
[9.6.19]: https://github.com/sebastianbergmann/phpunit/compare/9.6.18...9.6.19
diff --git a/composer.json b/composer.json
index e64534e0119..fbee5d8bc2d 100644
--- a/composer.json
+++ b/composer.json
@@ -30,7 +30,7 @@
"ext-xml": "*",
"ext-xmlwriter": "*",
"doctrine/instantiator": "^1.5.0 || ^2",
- "myclabs/deep-copy": "^1.12.0",
+ "myclabs/deep-copy": "^1.12.1",
"phar-io/manifest": "^2.0.4",
"phar-io/version": "^3.2.1",
"phpunit/php-code-coverage": "^9.2.32",
diff --git a/composer.lock b/composer.lock
index 134a41501d6..08fedc14339 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "c42c85dc63b776e13d9454ad6ff3ddc9",
+ "content-hash": "c2c8f2f519c0a987a4a2c8d3ffd9b3ce",
"packages": [
{
"name": "doctrine/instantiator",
@@ -78,16 +78,16 @@
},
{
"name": "myclabs/deep-copy",
- "version": "1.12.0",
+ "version": "1.12.1",
"source": {
"type": "git",
"url": "https://github.com/myclabs/DeepCopy.git",
- "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c"
+ "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c",
- "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c",
+ "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/123267b2c49fbf30d78a7b2d333f6be754b94845",
+ "reference": "123267b2c49fbf30d78a7b2d333f6be754b94845",
"shasum": ""
},
"require": {
@@ -126,7 +126,7 @@
],
"support": {
"issues": "https://github.com/myclabs/DeepCopy/issues",
- "source": "https://github.com/myclabs/DeepCopy/tree/1.12.0"
+ "source": "https://github.com/myclabs/DeepCopy/tree/1.12.1"
},
"funding": [
{
@@ -134,20 +134,20 @@
"type": "tidelift"
}
],
- "time": "2024-06-12T14:39:25+00:00"
+ "time": "2024-11-08T17:47:46+00:00"
},
{
"name": "nikic/php-parser",
- "version": "v4.19.1",
+ "version": "v4.19.4",
"source": {
"type": "git",
"url": "https://github.com/nikic/PHP-Parser.git",
- "reference": "4e1b88d21c69391150ace211e9eaf05810858d0b"
+ "reference": "715f4d25e225bc47b293a8b997fe6ce99bf987d2"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/4e1b88d21c69391150ace211e9eaf05810858d0b",
- "reference": "4e1b88d21c69391150ace211e9eaf05810858d0b",
+ "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/715f4d25e225bc47b293a8b997fe6ce99bf987d2",
+ "reference": "715f4d25e225bc47b293a8b997fe6ce99bf987d2",
"shasum": ""
},
"require": {
@@ -156,7 +156,7 @@
},
"require-dev": {
"ircmaxell/php-yacc": "^0.0.7",
- "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0"
+ "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0"
},
"bin": [
"bin/php-parse"
@@ -188,9 +188,9 @@
],
"support": {
"issues": "https://github.com/nikic/PHP-Parser/issues",
- "source": "https://github.com/nikic/PHP-Parser/tree/v4.19.1"
+ "source": "https://github.com/nikic/PHP-Parser/tree/v4.19.4"
},
- "time": "2024-03-17T08:10:35+00:00"
+ "time": "2024-09-29T15:01:53+00:00"
},
{
"name": "phar-io/manifest",
@@ -1646,7 +1646,7 @@
"packages-dev": [],
"aliases": [],
"minimum-stability": "stable",
- "stability-flags": [],
+ "stability-flags": {},
"prefer-stable": true,
"prefer-lowest": false,
"platform": {
@@ -1658,7 +1658,7 @@
"ext-xml": "*",
"ext-xmlwriter": "*"
},
- "platform-dev": [],
+ "platform-dev": {},
"platform-overrides": {
"php": "7.3.0"
},
diff --git a/src/Framework/Constraint/Operator/UnaryOperator.php b/src/Framework/Constraint/Operator/UnaryOperator.php
index 9a69a474877..f8c24a52abc 100644
--- a/src/Framework/Constraint/Operator/UnaryOperator.php
+++ b/src/Framework/Constraint/Operator/UnaryOperator.php
@@ -10,7 +10,6 @@
namespace PHPUnit\Framework\Constraint;
use function count;
-
use SebastianBergmann\RecursionContext\InvalidArgumentException;
/**
diff --git a/src/Framework/Constraint/String/IsJson.php b/src/Framework/Constraint/String/IsJson.php
index 08aeaaf9ff2..bdf363326b9 100644
--- a/src/Framework/Constraint/String/IsJson.php
+++ b/src/Framework/Constraint/String/IsJson.php
@@ -10,7 +10,6 @@
namespace PHPUnit\Framework\Constraint;
use function json_decode;
-
use function json_last_error;
use function sprintf;
use SebastianBergmann\RecursionContext\InvalidArgumentException;
diff --git a/src/Framework/Constraint/Traversable/TraversableContains.php b/src/Framework/Constraint/Traversable/TraversableContains.php
index 829aab4193b..0f934396e77 100644
--- a/src/Framework/Constraint/Traversable/TraversableContains.php
+++ b/src/Framework/Constraint/Traversable/TraversableContains.php
@@ -10,7 +10,6 @@
namespace PHPUnit\Framework\Constraint;
use function is_array;
-
use function sprintf;
use SebastianBergmann\RecursionContext\InvalidArgumentException;
diff --git a/src/Framework/Constraint/Type/IsType.php b/src/Framework/Constraint/Type/IsType.php
index 5a968a30ad2..285b74a77e2 100644
--- a/src/Framework/Constraint/Type/IsType.php
+++ b/src/Framework/Constraint/Type/IsType.php
@@ -10,7 +10,6 @@
namespace PHPUnit\Framework\Constraint;
use function gettype;
-
use function is_array;
use function is_bool;
use function is_callable;
diff --git a/src/Framework/TestCase.php b/src/Framework/TestCase.php
index 28b5b245c91..30dd5b954dc 100644
--- a/src/Framework/TestCase.php
+++ b/src/Framework/TestCase.php
@@ -599,7 +599,7 @@ public function expectOutputString(string $expectedString): void
}
/**
- * @psalm-param class-string<\Throwable> $exception
+ * @psalm-param class-string $exception
*/
public function expectException(string $exception): void
{
diff --git a/src/Runner/Filter/Factory.php b/src/Runner/Filter/Factory.php
index b7d83b9f849..4880470eaf2 100644
--- a/src/Runner/Filter/Factory.php
+++ b/src/Runner/Filter/Factory.php
@@ -24,7 +24,7 @@
final class Factory
{
/**
- * @psalm-var array
+ * @psalm-var array
*/
private $filters = [];
diff --git a/src/Runner/Version.php b/src/Runner/Version.php
index f7b94b5df15..0e8638cb9b3 100644
--- a/src/Runner/Version.php
+++ b/src/Runner/Version.php
@@ -44,7 +44,7 @@ public static function id(): string
}
if (self::$version === '') {
- self::$version = (new VersionId('9.6.21', dirname(__DIR__, 2)))->getVersion();
+ self::$version = (new VersionId('9.6.22', dirname(__DIR__, 2)))->getVersion();
assert(!empty(self::$version));
}
diff --git a/src/TextUI/XmlConfiguration/Loader.php b/src/TextUI/XmlConfiguration/Loader.php
index 7a7786b6841..fa677212cd8 100644
--- a/src/TextUI/XmlConfiguration/Loader.php
+++ b/src/TextUI/XmlConfiguration/Loader.php
@@ -50,6 +50,7 @@
use PHPUnit\TextUI\XmlConfiguration\Logging\TestDox\Xml as TestDoxXml;
use PHPUnit\TextUI\XmlConfiguration\Logging\Text;
use PHPUnit\TextUI\XmlConfiguration\TestSuite as TestSuiteConfiguration;
+use PHPUnit\TextUI\XmlConfigurationTest;
use PHPUnit\Util\TestDox\CliTestDoxPrinter;
use PHPUnit\Util\VersionComparisonOperator;
use PHPUnit\Util\Xml;
@@ -702,7 +703,7 @@ private function legacyCodeCoverage(string $filename, DOMXPath $xpath, DOMDocume
* If $value is 'false' or 'true', this returns the value that $value represents.
* Otherwise, returns $default, which may be a string in rare cases.
*
- * @see \PHPUnit\TextUI\XmlConfigurationTest::testPHPConfigurationIsReadCorrectly
+ * @see XmlConfigurationTest::testPHPConfigurationIsReadCorrectly
*
* @param bool|string $default
*
diff --git a/tests/_files/ExceptionInTestDetectedInTeardown.php b/tests/_files/ExceptionInTestDetectedInTeardown.php
index a81763f8cf4..38167810703 100644
--- a/tests/_files/ExceptionInTestDetectedInTeardown.php
+++ b/tests/_files/ExceptionInTestDetectedInTeardown.php
@@ -11,7 +11,6 @@
use Exception;
use PHPUnit\Framework\TestCase;
-
use PHPUnit\Runner\BaseTestRunner;
class ExceptionInTestDetectedInTeardown extends TestCase
diff --git a/tests/unit/Util/TestClassTest.php b/tests/unit/Util/TestClassTest.php
index f0dac611e56..40e2757a529 100644
--- a/tests/unit/Util/TestClassTest.php
+++ b/tests/unit/Util/TestClassTest.php
@@ -983,7 +983,6 @@ public function testWithVariousIterableDataProvidersFromParent(): void
['P'],
['Q'],
['R'],
-
], $dataSets);
}
@@ -1001,7 +1000,6 @@ public function testWithVariousIterableDataProvidersInParent(): void
['P'],
['Q'],
['R'],
-
], $dataSets);
}
@@ -1019,7 +1017,6 @@ public function testWithVariousIterableAbstractDataProviders(): void
['Y'],
['Z'],
['P'],
-
], $dataSets);
}
@@ -1411,7 +1408,6 @@ public function getLinesToBeCoveredProvider(): array
[
TEST_FILES_PATH . 'CoveredClass.php' => range(37, 41),
],
-
],
[
CoveragePublicTest::class,
diff --git a/tools/composer b/tools/composer
index 4f021d637e7..f5d9d1ab15e 100755
Binary files a/tools/composer and b/tools/composer differ
diff --git a/tools/php-cs-fixer b/tools/php-cs-fixer
index d071fa55254..e08a0ea9f64 100755
Binary files a/tools/php-cs-fixer and b/tools/php-cs-fixer differ
diff --git a/tools/phpab b/tools/phpab
index e67d3430e2a..01e881632c9 100755
--- a/tools/phpab
+++ b/tools/phpab
@@ -150,22 +150,22 @@ spl_autoload_register(
);
Phar::mapPhar('phpab.phar');
-define('PHPAB_VERSION', '1.29.1');
+define('PHPAB_VERSION', '1.29.2');
$factory = new \TheSeer\Autoload\Factory();
$factory->getCLI()->run($_SERVER);
exit(0);
__HALT_COMPILER(); ?>
�* �
- phpab.phar 8 vendor/theseer/directoryscanner/src/directoryscanner.php�" 8�/fG �P�� 7 vendor/theseer/directoryscanner/src/filesonlyfilter.php�
- 8�/f� ��;l� <