Fix bin/publish: use correct .env path for rspade_system Fix bin/publish script: prevent grep exit code 1 from terminating script 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
26 KiB
Executable File
26 KiB
Executable File
Changes in PHPUnit 10.5
All notable changes of the PHPUnit 10.5 release series are documented in this file using the Keep a CHANGELOG principles.
10.5.53 - 2025-08-20
Changed
- Do not configure
report_memleakssetting (which will be deprecated in PHP 8.5) for PHPT processes
10.5.52 - 2025-08-16
Changed
- #6321: Allow
error_reporting=E_ALLfor--check-php-configuration
10.5.51 - 2025-08-12
Changed
- #6308: Improve output of
--check-php-configuration - The version number for the test result cache file has been incremented to reflect that its structure for PHPUnit 10.5 is not compatible with its structure for PHPUnit 8.5 and PHPUnit 9.6
10.5.50 - 2025-08-10
Changed
- #6300: Emit warning when the name of a data provider method begins with
test - Do not use
SplObjectStoragemethods that will be deprecated in PHP 8.5
10.5.49 - 2025-08-09
Added
- #6297:
--check-php-configurationCLI option for checking whether PHP is configured for testing
Fixed
- Errors due to invalid data provided using
#[TestWith]or#[TestWithJson]attributes are now properly reported
10.5.48 - 2025-07-11
Fixed
- #6254:
defects,randomconfiguration is supported by implementation, but it is not allowed by the XML configuration file schema
10.5.47 - 2025-06-20
Added
- #6236:
failOnPhpunitWarningattribute on the<phpunit>element of the XML configuration file and--fail-on-phpunit-warningCLI option for controlling whether PHPUnit should fail on PHPUnit warnings (default:true) - #6239:
--do-not-fail-on-deprecation,--do-not-fail-on-phpunit-warning,--do-not-fail-on-phpunit-deprecation,--do-not-fail-on-empty-test-suite,--do-not-fail-on-incomplete,--do-not-fail-on-notice,--do-not-fail-on-risky,--do-not-fail-on-skipped, and--do-not-fail-on-warningCLI options --do-not-report-useless-testsCLI option as a replacement for--dont-report-useless-tests
Deprecated
--dont-report-useless-testsCLI option (use--do-not-report-useless-testsinstead)
Fixed
- #6243: Constraints cannot be implemented without using internal class
ExpectationFailedException
10.5.46 - 2025-05-02
Added
displayDetailsOnAllIssuesattribute on the<phpunit>element of the XML configuration file and--display-all-issuesCLI option for controlling whether PHPUnit should display details on all issues that are triggered (default:false)failOnAllIssuesattribute on the<phpunit>element of the XML configuration file and--fail-on-all-issuesCLI option for controlling whether PHPUnit should fail on all issues that are triggered (default:false)
Changed
- #5956: Improved handling of deprecated
E_STRICTconstant - Improved message when test is considered risky for printing unexpected output
10.5.45 - 2025-02-06
Changed
- #6117: Include source location information for issues triggered during test in
--debugoutput - #6119: Improve message for errors that occur while parsing attributes
10.5.44 - 2025-01-31
Fixed
- #6115: Backed enumerations with values not of type
stringcannot be used in customized TestDox output
10.5.43 - 2025-01-29
Changed
- Do not skip execution of test that depends on a test that is larger than itself
10.5.42 - 2025-01-28
Fixed
- #6103: Output from test run in separate process is printed twice
- #6109: Skipping a test in a before-class method crashes JUnit XML logger
- #6111: Deprecations cause
SourceMapperto scan all<source/>files
10.5.41 - 2025-01-13
Added
Test\AfterLastTestMethodErrored,Test\AfterTestMethodErrored,Test\BeforeTestMethodErrored,Test\PostConditionErrored, andTest\PreConditionErroredevents
Fixed
- #6094: Errors in after-last-test methods are not reported
- #6095: Expectation is not counted correctly when a doubled method is called more often than is expected
- #6098: No
system-outelement in JUnit XML logfile
10.5.40 - 2024-12-21
Fixed
- #6082:
assertArrayHasKey(),assertArrayNotHasKey(),arrayHasKey(), andArrayHasKey::__construct()do not support all possible key types - #6087:
--migrate-configurationdoes not removebeStrictAboutTodoAnnotatedTestsattribute from XML configuration file
10.5.39 - 2024-12-11
Added
- #6081:
DefaultResultCache::mergeWith()for merging result cache instances
Fixed
- #6066: TeamCity logger does not handle error/skipped events in before-class methods correctly
10.5.38 - 2024-10-28
Changed
- #6012: Remove empty lines between TeamCity events
10.5.37 - 2024-10-19
Fixed
- #5982: Typo in exception message
10.5.36 - 2024-10-08
Changed
- #5957: Skip data provider build when requirements are not satisfied
- #5969: Check for requirements before creating a separate process
- Updated regular expressions used by
StringMatchesFormatDescriptionconstraint to be consistent with PHP'srun-tests.php
Fixed
- #5965:
PHPUnit\Framework\Exceptiondoes not handle string error codes (PDOExceptionwith error code'HY000', for example)
10.5.35 - 2024-09-19
Changed
- #5956: Deprecation of the
E_STRICTconstant in PHP 8.4
Fixed
- #5950: TestDox text should not be
trim()med when it contains$character - The attribute parser will no longer try to instantiate attribute classes that do not exist
10.5.34 - 2024-09-13
Fixed
- #5931: Reverted addition of
nameproperty on<testsuites>element in JUnit XML logfile - #5946:
Callbackthrows aTypeErrorwhen checking acallablehas variadic parameters
10.5.33 - 2024-09-09
Fixed
- #4584:
assertJsonStringEqualsJsonString()considers objects with sequential numeric keys equal to be arrays - #4625: Generator yielding keys that are neither integer or string leads to hard-to-understand error message when used as data provider
- #4674: JSON assertions should treat objects as unordered
- #5891:
Callbackconstraint does not handle variadic arguments correctly when used for mock object expectations - #5929: TestDox output containing
$at the beginning gets truncated when used with a data provider
10.5.32 - 2024-09-04
Added
- #5937:
failOnPhpunitDeprecationattribute on the<phpunit>element of the XML configuration file and--fail-on-phpunit-deprecationCLI option for controlling whether PHPUnit deprecations should be considered when determining the test runner's shell exit code (default: do not consider) displayDetailsOnPhpunitDeprecationsattribute on the<phpunit>element of the XML configuration file and--display-phpunit-deprecationsCLI option for controlling whether details on PHPUnit deprecations should be displayed (default: do not display)
Changed
- #5937: PHPUnit deprecations will, by default, no longer affect the test runner's shell exit code. This can optionally be turned back on using the
--fail-on-phpunit-deprecationCLI option or thefailOnPhpunitDeprecation="true"attribute on the<phpunit>element of the XML configuration file. - Details for PHPUnit deprecations will, by default, no longer be displayed. This can optionally be turned back on using the
--display-phpunit-deprecationsCLI option or thedisplayDetailsOnPhpunitDeprecationsattribute on the<phpunit>element of the XML configuration file.
10.5.31 - 2024-09-03
Changed
- #5931:
nameproperty on<testsuites>element in JUnit XML logfile - Removed
.phpstorm.meta.phpfile as methods such asTestCase::createStub()use generics / template types for their return types and PhpStorm, for example, uses that information
Fixed
- #5884: TestDox printer does not consider that issues can be suppressed by attribute, baseline, source location, or
@operator
10.5.30 - 2024-08-13
Changed
- Improved error message when stubbed method is called more often than return values were configured for it
10.5.29 - 2024-07-30
Fixed
- #5887: Issue baseline generator does not correctly handle ignoring suppressed issues
- #5908:
--list-testsand--list-tests-xmlCLI options do not report error when data provider method throws exception
10.5.28 - 2024-07-18
Fixed
- #5898:
Test\Passedevent is not emitted for PHPT tests --coverage-filterCLI option could not be used multiple times
10.5.27 - 2024-07-10
Changed
- Updated dependencies (so that users that install using Composer's
--prefer-lowestCLI option also get recent versions)
Fixed
- #5892: Errors during write of
phpunit.xmlare not handled correctly when--generate-configurationis used
10.5.26 - 2024-07-08
Added
--only-summary-for-coverage-textCLI option to reduce the code coverage report in text format to a summary--show-uncovered-for-coverage-textCLI option to expand the code coverage report in text format to include a list of uncovered files
10.5.25 - 2024-07-03
Changed
- Updated dependencies for PHAR distribution
10.5.24 - 2024-06-20
Changed
- #5877: Use
array_pop()instead ofarray_shift()for processingTestobjects inTestSuite::run()and optimizeTestSuite::isEmpty()
10.5.23 - 2024-06-20
Changed
- #5875: Also destruct
TestCaseobjects early that use a data provider
10.5.22 - 2024-06-19
Changed
- #5871: Do not collect unnecessary information using
debug_backtrace()
10.5.21 - 2024-06-15
Changed
- #5861: Destroy
TestCaseobject after its test was run
10.5.20 - 2024-04-24
- #5771: JUnit XML logger may crash when test that is run in separate process exits unexpectedly
- #5819: Duplicate keys from different data providers are not handled properly
10.5.19 - 2024-04-17
Fixed
- #5818: Calling
method()on a test stub created usingcreateStubForIntersectionOfInterfaces()throws an unexpected exception
10.5.18 - 2024-04-14
Deprecated
- #5812: Support for string array keys in data sets returned by data provider methods that do not match the parameter names of the test method(s) that use(s) them
Fixed
- #5795: Using
@testWithannotation may generatePHP Warning: Uninitialized string offset 0
10.5.17 - 2024-04-05
Changed
- The namespaces of dependencies are now prefixed with
PHPUnitPHARinstead of justPHPUnitfor the PHAR distribution of PHPUnit
10.5.16 - 2024-03-28
Changed
- #5766: Do not use a shell in
proc_open()if not really needed - #5772: Cleanup process handling after dropping temp-file handling
Fixed
- #5570: Windows does not support exclusive locks on stdout
10.5.15 - 2024-03-22
Fixed
- #5765: Be more forgiving with error handlers that do not respect error suppression
10.5.14 - 2024-03-21
Changed
- #5747: Cache result of
Groups::groups() - #5748: Improve performance of
NamePrettifier::prettifyTestMethodName() - #5750: Micro-optimize
NamePrettifier::prettifyTestMethodName()once again
Fixed
- #5760: TestDox printer does not display details about exceptions raised in before-test methods
10.5.13 - 2024-03-12
Changed
- #5727: Prevent duplicate call of
NamePrettifier::prettifyTestMethodName() - #5739: Micro-optimize
NamePrettifier::prettifyTestMethodName() - #5740: Micro-optimize
TestRunner::runTestWithTimeout() - #5741: Save call to
Telemetry\System::snapshot() - #5742: Prevent file IO when not strictly necessary
- #5743: Prevent unnecessary
ExecutionOrderDependency::getTarget()call - #5744: Simplify
NamePrettifier::prettifyTestMethodName()
Fixed
- #5351: Incorrect code coverage metadata does not prevent code coverage data from being collected
- #5746: Using
-dCLI option multiple times triggers warning
10.5.12 - 2024-03-09
Fixed
- #5652:
HRTime::duration()throwsInvalidArgumentException
10.5.11 - 2024-02-25
Fixed
- #5704: No warning when CLI options are used multiple times
- #5707:
--fail-on-empty-test-suiteCLI option is not documented in--helpoutput - No warning when the
#[CoversClass]and#[UsesClass]attributes are used with the name of an interface - Resource usage information is printed when the
--debugCLI option is used
10.5.10 - 2024-02-04
Changed
- Improve output of
--check-versionCLI option - Improve description of
--check-versionCLI option
Fixed
- #5692:
--log-events-textand--log-events-verbose-textrequire the destination file to exit
10.5.9 - 2024-01-22
Changed
- Show help for
--manifest,--sbom, and--composer-lockwhen the PHAR is used
Fixed
- #5676: PHPUnit's test runner overwrites custom error handler registered using
set_error_handler()in bootstrap script
10.5.8 - 2024-01-19
Fixed
- #5673: Confusing error message when migration of a configuration is requested that does not need to be migrated
10.5.7 - 2024-01-14
Fixed
- #5662: PHPUnit errors out on startup when the
ctypeextension is not loaded but a polyfill for it was installed
10.5.6 - 2024-01-13
Added
- Added the
--debugCLI option as an alias for--no-output --log-events-text php://stdout
Fixed
- #5455:
willReturnCallback()does not pass unknown named variadic arguments to callback - #5488: Details about tests that are considered risky are not displayed when the TestDox result printer is used
- #5516: Assertions that use the
LogicalNotconstraint (assertNotEquals(),assertStringNotContainsString(), ...) can generate confusing failure messages - #5518: Details about deprecations, notices, and warnings are not displayed when the TestDox result printer is used
- #5574: Wrong backtrace line is reported
- #5633:
--log-events-textand--log-events-verbose-textCLI options do not handle absolute and relative paths - #5634: Exceptions in the destructor of a test double are ignored
- #5641: The
TestSuitevalue object returned byTestSuite\Filtered::testSuite()contains all tests instead of only the filtered tests
10.5.5 - 2023-12-27
Fixed
- #5619: Reverted change introduced in PHPUnit 10.5.4 that broke backward compatibility
10.5.4 - 2023-12-27
Fixed
- #5592: Error Handler prevents
error_get_last()usage in tests - #5592:
E_USER_ERRORdoes not abort test execution - #5612: Empty
<coverage>element in XML configuration after migrating configuration - #5616: Values from data provider are not shown for failed test
- #5619: Check and restore error/exception global handlers
- #5621: Name of data set is missing from TeamCity output
10.5.3 - 2023-12-13
Changed
- Make PHAR build reproducible (the only remaining differences were in the timestamps for the files in the PHAR)
Deprecated
Test\AssertionFailedandTest\AssertionSucceededeventsPHPUnit\Runner\Extension\Facade::requireExportOfObjects()andPHPUnit\Runner\Extension\Facade::requiresExportOfObjects()registerMockObjectsFromTestArgumentsRecursivelyattribute on the<phpunit>element of the XML configuration filePHPUnit\TextUI\Configuration\Configuration::registerMockObjectsFromTestArgumentsRecursively()
Fixed
- #5614: Infinite recursion when data provider provides recursive array
10.5.2 - 2023-12-05
Fixed
- #5561: JUnit XML logger does not handle assertion failures in before-test methods
- #5567: Infinite recursion when recursive / self-referencing arrays are checked whether they contain only scalar values
10.5.1 - 2023-12-01
Fixed
- #5593: Return Value Generator fails to correctly create test stub for method with
staticreturn type declaration when used recursively - #5596:
PHPUnit\Framework\TestCasehas@internalannotation in PHAR
10.5.0 - 2023-12-01
Added
- #5532:
#[IgnoreDeprecations]attribute to ignoreE_(USER_)DEPRECATEDissues on test class and test method level - #5551: Support for omitting parameter default values for
willReturnMap() - #5577:
--composer-lockCLI option for PHAR binary that displays thecomposer.lockused to build the PHAR
Changed
MockBuilder::disableAutoReturnValueGeneration()andMockBuilder::enableAutoReturnValueGeneration()are no longer deprecated
Fixed
- #5563:
createMockForIntersectionOfInterfaces()does not automatically register mock object for expectation verification