MokkeryCallLogger
class MokkeryCallLogger(lineTransformer: (String) -> String = { it }, loggingFunction: (String) -> Unit = ::println) : MokkeryCallListener
Logs each mock call with loggingFunction. By default, the loggingFunction is println.
Log line can be changed using lineTransformer.
To enable the logger, it has to be registered in a hook.
Example:
MokkeryCallInterceptor
.beforeAnswering
.register(MokkeryCallLogger())
Content copied to clipboard
Functions
Link copied to clipboard
Do not override this method to keep MokkeryCallListener behaviour as intended.
Link copied to clipboard