| blib/lib/Raisin/Logger.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % |
| statement | 9 | 9 | 100.0 |
| branch | n/a | ||
| condition | n/a | ||
| subroutine | 4 | 4 | 100.0 |
| pod | 1 | 2 | 50.0 |
| total | 14 | 15 | 93.3 |
| line | stmt | bran | cond | sub | pod | time | code |
|---|---|---|---|---|---|---|---|
| 1 | #!perl | ||||||
| 2 | #PODNAME: Raisin::Logger | ||||||
| 3 | #ABSTRACT: Default logger for Raisin. | ||||||
| 4 | |||||||
| 5 | 7 | 7 | 75226 | use strict; | |||
| 7 | 27 | ||||||
| 7 | 221 | ||||||
| 6 | 7 | 7 | 37 | use warnings; | |||
| 7 | 12 | ||||||
| 7 | 963 | ||||||
| 7 | |||||||
| 8 | package Raisin::Logger; | ||||||
| 9 | $Raisin::Logger::VERSION = '0.92'; | ||||||
| 10 | my $FH = *STDERR; | ||||||
| 11 | |||||||
| 12 | 7 | 7 | 0 | 1255 | sub new { bless {}, shift } | ||
| 13 | |||||||
| 14 | sub log { | ||||||
| 15 | 4 | 4 | 1 | 2703 | my ($self, %args) = @_; | ||
| 16 | 4 | 73 | printf $FH '%s %s', uc($args{level}), $args{message}; | ||||
| 17 | } | ||||||
| 18 | |||||||
| 19 | 1; | ||||||
| 20 | |||||||
| 21 | __END__ |