brianhenryie/color-logger

A PSR logger that prints to the console in colour. For tests.

1.2.0 2023-02-27 18:55 UTC

This package is auto-updated.

Last update: 2024-11-17 07:57:56 UTC


README

A PSR-3 logger to use during PHPUnit tests.

Prints the log level in colour, the message as normal, no time, and no context.

Wonderful, wonderful colours

composer require --dev brianhenryie/color-logger

Then, presuming your classes use LoggerAwareTrait:

$myclass = new MyClass();
$colorLogger = new \BrianHenryIE\ColorLogger\ColorLogger();
$myclass->setLogger($colorLogger);