loris has asked for the wisdom of the Perl Monks concerning the following question:
Hello all,
In a module I have
use Log::Log4perl qw(get_logger); our $log = Log::Log4perl->get_logger(__PACKAGE__);
I do
Log::Log4perl->init("log.conf");
in a script which uses the module. This works OK, but when I test the module with a script which does not initialise the logging mechanism I get, logically enough,
Log4perl: Seems like no initialization happened. Forgot to call init() +?
Is there a smart way to switch off the logging when I'm testing? Or should I just go the whole log-hog and log the tests? If the latter, why?
Thanks,
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Simple::Testing and Log::Log4perling
by saintmike (Vicar) on Nov 24, 2004 at 09:12 UTC | |
|
Re: Simple::Testing and Log::Log4perling
by aquarium (Curate) on Nov 24, 2004 at 10:19 UTC |