blib/lib/auto/share/dist/Cmd-Dwarf/app/lib/Dwarf/Plugin/Now.pm untested

filter: Statementstmt 0.0% 0 / 14 Branchbran n/a Conditioncond 0.0% 0 / 5 MC/DCmcdc 0.0% 0 / 3 Subroutinesub 0.0% 0 / 4 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 27 CC 1 SCAR 6.9
CC
1
Cov
0%
init
2.0
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 package Dwarf::Plugin::Now;
2 use Dwarf::Pragma;
3 use Dwarf::Util qw/add_method/;
4 use DateTime;
5  
6 sub init {
7 my ($class, $c, $conf) = @_;
8 $conf ||= {};
9  
10 add_method($c, now => sub {
11 my $self = shift;
12 $self->{'dwarf.now'} ||= DateTime->now(%$conf);
13 });
14 }
15  
16 1;