[TASK] Do not set GeneralUtility::$container in unit tests
The GeneralUtility $container instance should only be set/used in functional tests as we a) can not reset the instance (which means other unit tests are affected) and b) should mock/inject dependencies in unit tests. TreeDataProviderFactoryTest is therefore changed to to use GeneralUtility::addInstance() (which is intended for unit tests) instead of GeneralUtility::setContainer(). Change-Id: I9fc0e76077cc1cc2a6935d025b97309efc315f4f Releases: master Resolves: #89890 Related: #89733 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62573 Tested-by:TYPO3com <noreply@typo3.com> Tested-by:
Susanne Moog <look@susi.dev> Tested-by:
Andreas Fernandez <a.fernandez@scripting-base.de> Reviewed-by:
Susanne Moog <look@susi.dev> Reviewed-by:
Andreas Fernandez <a.fernandez@scripting-base.de>
Please register or sign in to comment