-----------------------------------------------------------
Brainfuck - having now a dependency injection cycle
ResourceFactory -> StorageRepository
StorageRepository -> ResourceFactory
because `ResourceStorage` instantiated manually within the
StorageRepository requires the ResourceFactory instance to
executed cross storage handling code.
Needs a solution for the fuckup to disband the (hidden)
cycling dependency chain
-----------------------------------------------------------
`ResourceStorage` needs to use `ResourceFactory` for some
operations and thus using `GeneralUtility::makeInstance()`
to retrieve the shared factory instance.
Usually a `ResourceStorage` instance is created by the
`StorageRepository` which is already DI aware and get
services injected.
This change modifies the `ResourceStorage` constructor to
allow injection of the `ResourceFactory` with fallback to
`GeneralUtility::makeInstance()` for now if a instance is
created manualy by 3rd party code. The `StorageRepository`
now also gets the `ResourceFactory` injected and uses it
to create `ResourceStorage` instances.
Note that `ResourceStorage` provides the public method
`getResourceFactoryInstance()` and must thus be taken
as public API which is not an issue here as we provide
the injected ResourceFactory instead.
Related test are aligned to inject the resource factory
if necessary.