i guess youre asking yourself now where do i get the ControllerContext?
its use in fusion is for the global request object: ${request} or when using Neos.Neos:ConvertUris for example.
there are some options as far as i know:
1
either you create an actual fake controller context:
2
or you create it from the eviroment:
3
or you just put in a dummy by extending Neos\Flow\Mvc\Controller\ControllerContext and overriding the contructor to empty, basically a mock. (which doenst work at all and will throw when its called)