Branch Coverage

blib/lib/Dancer/Logger/File/PerRequest.pm
Criterion Covered Total %
branch 5 38 13.1


line true false branch
28 0 1 unless $logdir
29 0 1 unless -d $logdir
35 0 0 'Dancer::SharedData'->request ? :
43 1 0 unless $$self{'fh'}
52 0 1 if (setting('serializer'))
61 0 0 unless ($fh)
63 0 0 unless my $logdir = logdir()
66 0 0 unless ($fh = open_file('>>', $logfile))
80 0 0 unless ref $fh and $fh->opened
82 0 0 unless flock $fh, 2
84 0 0 unless seek $fh, 0, 2
86 0 0 unless $fh->print($self->format_message($level, $message))
88 0 0 unless flock $fh, 8
94 1 0 if (my $altpath = setting('log_path'))
100 0 0 if ($logroot and not -d $logroot and not mkdir($logroot))
105 0 0 $logroot ? :
109 0 0 if -d $expected_path and -x _ and -w _
111 0 0 unless (-w $logroot and -x _)
114 0 0 unless (-w $logroot and -x _)