[TASK] Avoid phpunit addMethods()
phpunit 11 deprecates addMethods() on mocks. There are various solutions: * Use onlyMethods([]) instead of addMethods(['dummy']) to "mock nothing" * Remove a couple of calls that were bogus in the first place * Turn calls into mocks of interfaces * Turn calls into mocks of fixture classes * Instantiate a subject with new() Also have the one or the other minor cleanup as drive-by. Change-Id: I5dad1cc65c14ed50b3941beaa7132040bc415a11 Resolves: #103218 Releases: main Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/83150 Tested-by:Anja Leichsenring <aleichsenring@ab-softlab.de> Reviewed-by:
Anja Leichsenring <aleichsenring@ab-softlab.de> Reviewed-by:
Oliver Klee <typo3-coding@oliverklee.de> Tested-by:
Oliver Klee <typo3-coding@oliverklee.de> Tested-by:
core-ci <typo3@b13.com> Reviewed-by:
Stefan Bürk <stefan@buerk.tech> Tested-by:
Stefan Bürk <stefan@buerk.tech>
Showing
- Build/phpstan/phpstan-baseline.neon 0 additions, 15 deletionsBuild/phpstan/phpstan-baseline.neon
- typo3/sysext/core/Tests/Functional/Cache/Backend/FileBackendTest.php 25 additions, 25 deletions...t/core/Tests/Functional/Cache/Backend/FileBackendTest.php
- typo3/sysext/core/Tests/Unit/Authentication/BackendUserAuthenticationTest.php 1 addition, 1 deletion...sts/Unit/Authentication/BackendUserAuthenticationTest.php
- typo3/sysext/core/Tests/Unit/Error/ProductionExceptionHandlerTest.php 2 additions, 12 deletions.../core/Tests/Unit/Error/ProductionExceptionHandlerTest.php
- typo3/sysext/core/Tests/Unit/Log/Writer/DatabaseWriterTest.php 1 addition, 4 deletions.../sysext/core/Tests/Unit/Log/Writer/DatabaseWriterTest.php
- typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php 1 addition, 1 deletiontypo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php
- typo3/sysext/core/Tests/Unit/Package/PackageManagerTest.php 5 additions, 66 deletionstypo3/sysext/core/Tests/Unit/Package/PackageManagerTest.php
- typo3/sysext/core/Tests/Unit/Resource/FileTest.php 3 additions, 11 deletionstypo3/sysext/core/Tests/Unit/Resource/FileTest.php
- typo3/sysext/core/Tests/Unit/Resource/MetaDataAspectTest.php 0 additions, 1 deletiontypo3/sysext/core/Tests/Unit/Resource/MetaDataAspectTest.php
- typo3/sysext/core/Tests/Unit/Resource/Processing/LocalPreviewHelperTest.php 1 addition, 1 deletion...Tests/Unit/Resource/Processing/LocalPreviewHelperTest.php
- typo3/sysext/core/Tests/Unit/Service/FlexFormServiceTest.php 1 addition, 4 deletionstypo3/sysext/core/Tests/Unit/Service/FlexFormServiceTest.php
- typo3/sysext/core/Tests/Unit/Utility/GeneralUtilityTest.php 2 additions, 8 deletionstypo3/sysext/core/Tests/Unit/Utility/GeneralUtilityTest.php
- typo3/sysext/extbase/Tests/Unit/Mvc/View/JsonViewTest.php 65 additions, 88 deletionstypo3/sysext/extbase/Tests/Unit/Mvc/View/JsonViewTest.php
- typo3/sysext/extbase/Tests/Unit/Persistence/Generic/BackendTest.php 3 additions, 19 deletions...xt/extbase/Tests/Unit/Persistence/Generic/BackendTest.php
- typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Fixtures/TearDownableBackendInterface.php 23 additions, 0 deletions...istence/Generic/Fixtures/TearDownableBackendInterface.php
- typo3/sysext/extbase/Tests/Unit/Persistence/Generic/PersistenceManagerTest.php 2 additions, 6 deletions...Tests/Unit/Persistence/Generic/PersistenceManagerTest.php
- typo3/sysext/extbase/Tests/Unit/Persistence/Generic/QueryFactoryTest.php 19 additions, 45 deletions...tbase/Tests/Unit/Persistence/Generic/QueryFactoryTest.php
- typo3/sysext/extbase/Tests/Unit/Utility/DebuggerUtilityTest.php 1 addition, 3 deletions...sysext/extbase/Tests/Unit/Utility/DebuggerUtilityTest.php
- typo3/sysext/fluid/Tests/Unit/Core/Rendering/RenderingContextTest.php 19 additions, 40 deletions.../fluid/Tests/Unit/Core/Rendering/RenderingContextTest.php
- typo3/sysext/frontend/Tests/Unit/ContentObject/CaseContentObjectTest.php 1 addition, 1 deletion...ontend/Tests/Unit/ContentObject/CaseContentObjectTest.php
Please register or sign in to comment