Support for setting up logging method which will be used in case of
fails and errors (with unittest).