Comments (4)
Brief update: The confidence Garvin has shown me that I will be able to solve the problem has motivated me to continue thinking about the problem and working on a solution.
I currently have the situation here (local, not committed and pushed) that @sbuerk's test is green. Whoopee! However, several other tests are red. Oh no!
Let's hope that I manage to turn all the tests green again ...
from phpunit.
Please don't get me wrong, I don't want to deny any blame, nor do I want to blame users of PHPUnit. The only person I blame is myself and I am sorry that PHPUnit 11.2 broke your tests.
Just dropping by to say that there's no blame at all, and those nightly tests are there for us to catch things early, and search for solutions. Thank you and @sbuerk for inspecting this so quickly, and I'm sure there'll be a solution. :-)
from phpunit.
PHPUnit 11.2 has added support for extendable classes that are declared readonly
to its test double functionality. This required extensive changes to the runtime internals of the test double functionality. These changes are the reason why tests like the one you have provided as an example no longer work. I am grateful to you for reporting this, as I was not aware of this problem before.
Side note: maybe we can discuss at the TYPO3 code sprint this week whether the TYPO3 project can also test in its nightly CI pipeline with the current development version of PHPUnit. This would allow us to uncover such problems earlier.
The problem you found is ultimately due to the fact that the test double functionality of PHPUnit supports not only interfaces, but also extendable classes. The fact that only a selection of the methods of an extendable class can be replaced makes the whole thing even worse.
Please don't get me wrong, I don't want to deny any blame, nor do I want to blame users of PHPUnit. The only person I blame is myself and I am sorry that PHPUnit 11.2 broke your tests.
I will try my best to fix this issue, but at least right now I am not very hopeful that it can be fixed (without reverting #5804).
from phpunit.
I have an idea how to solve this, now I need to find time to give it a try.
from phpunit.
Related Issues (20)
- Allow attributes for code coverage targeting to also be used on the test method level (instead of only on the test class level) HOT 4
- Allow enabling process isolation on suite/test base class HOT 1
- Include deprecation/warning failures in JUnit logs
- Multiple dataProviders testCases with same key (name) are not detected HOT 1
- Allow selected deprecations to be skipped/ignored HOT 1
- Run garbage collector on AfterLastTestMethodFinished HOT 2
- Fatal with some error/exception handlers HOT 3
- Issue5592Test fails when registering an error handler in an auto_prepend_file
- assertEquals() hides contents of long strings
- Suppressed deprecations not included in baseline when ignoreSuppressionOfDeprecations is true HOT 1
- parameter names $expected, $actual don't make sense for assertLessThan() & friends
- Missing extensions in php 8.2: `ctype` and `tokenizer` HOT 2
- Various output buffer issues HOT 4
- Github template comment deprecated php.ini directive log_errors_max_len HOT 1
- PHP-Scoper 0.18.12 breaks PHAR for PHPUnit 8.5 on PHP 7.2 HOT 8
- Smarter defaults for the display of warnings, notices & co
- XML Configuration File Migrator does not remove `cacheDirectory` attribute from `<coverage>` element when migrating from PHPUnit 11.1 to PHPUnit 11.2 HOT 2
- Running tests with process isolation does not allow defining auto_prepend_file for child processes
- TestDox printer does not show previous exception
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from phpunit.