- you don't need to check the return value (the function is not called anyway). You should set mock expectation on the arguments received by ``writeZendMonitorCustomEvent``

- ``Monolog\Logger`` does not provide ``$record['formatted']`` either. It is added by the handler in ``handle`` before calling ``write``