| blib/lib/Mojolicious/Plugin/Log/Timestamp.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % |
| statement | 10 | 10 | 100.0 |
| branch | n/a | ||
| condition | n/a | ||
| subroutine | 3 | 3 | 100.0 |
| pod | 1 | 1 | 100.0 |
| total | 14 | 14 | 100.0 |
| line | stmt | bran | cond | sub | pod | time | code |
|---|---|---|---|---|---|---|---|
| 1 | package Mojolicious::Plugin::Log::Timestamp; | ||||||
| 2 | 2 | 2 | 323284 | use Mojolicious::Plugin -base; | |||
| 2 | 427 | ||||||
| 2 | 14 | ||||||
| 3 | |||||||
| 4 | 2 | 2 | 880 | use Mojar::Log; | |||
| 2 | 97896 | ||||||
| 2 | 8 | ||||||
| 5 | |||||||
| 6 | our $VERSION = 0.031; | ||||||
| 7 | |||||||
| 8 | sub register { | ||||||
| 9 | 1 | 1 | 1 | 9557 | my ($self, $app, $cfg) = @_; | ||
| 10 | 1 | 13 | my $log = Mojar::Log->new($cfg); | ||||
| 11 | 1 | 27 | $app->log($log); | ||||
| 12 | 1 | 5 | $app->log->debug(q{Customised log timestamps}); | ||||
| 13 | } | ||||||
| 14 | |||||||
| 15 | 1; | ||||||
| 16 | __END__ |