Closed
Description
Symfony version(s) affected
8.0.0
Description
#60962 and #60973 made two classes, DataCollectorTranslator
and ServicesResetter
, final that cannot be doubled anymore in tests resulting in failed tests.
How to reproduce
See https://github.com/symfony/symfony/actions/runs/15980198054/job/45072578797?pr=60987
1) Symfony\Component\Translation\Tests\DataCollector\TranslationDataCollectorTest::testCollectEmptyMessages
PHPUnit\Framework\MockObject\ClassIsFinalException: Class "Symfony\Component\Translation\DataCollectorTranslator" is declared "final" and cannot be doubled
1) Symfony\Component\Messenger\Tests\EventListener\ResetServicesListenerTest::testResetServices with data set #0 (true)
PHPUnit\Framework\MockObject\ClassIsFinalException: Class "Symfony\Component\HttpKernel\DependencyInjection\ServicesResetter" is declared "final" and cannot be doubled
Possible Solution
No response
Additional Context
No response