[TASK] Create a Getter for CacheManager inside Datahandler 88/31288/2
authorStefano Kowalke <blueduck@gmx.net>
Wed, 2 Jul 2014 11:26:16 +0000 (13:26 +0200)
committerThomas Maroschik <tmaroschik@dfau.de>
Wed, 2 Jul 2014 12:00:49 +0000 (14:00 +0200)
commit09915b3e69cd7152ecac5a05c99cc20e18b52c9c
tree380df9a0678e8dd20dd88352d55d6bdd641ee99e
parent94ff67e802e287dd1ac0a46de211c589eeca3828
[TASK] Create a Getter for CacheManager inside Datahandler

At the moment the CacheManager is created by
GeneralUtility::makeInstance(
  'TYPO3\\CMS\\Core\\Cache\\CacheManager'
); within the code. This makes the particular method untestable.

Solution: Create a Getter which creates and returns the instance.
This getter can be mocked.

Resolves: #60059
Releases: 6.2, 6.3
Change-Id: I9f83ec017da94778e542410cc9d03faacddc245c
Reviewed-on: https://review.typo3.org/31288
Reviewed-by: Anja Leichsenring
Tested-by: Anja Leichsenring
Reviewed-by: Alexander Opitz
Tested-by: Alexander Opitz
Reviewed-by: Thomas Maroschik
Tested-by: Thomas Maroschik
typo3/sysext/core/Classes/DataHandling/DataHandler.php