File Coverage

blib/lib/Gruntmaster/App/Command.pm
Criterion Covered Total %
statement 17 26 65.3
branch n/a
condition n/a
subroutine 6 7 85.7
pod 1 1 100.0
total 24 34 70.5


line stmt bran cond sub pod time code
1             package Gruntmaster::App::Command;
2              
3 1     1   987 use 5.014000;
  1         4  
4 1     1   4 use strict;
  1         2  
  1         18  
5 1     1   5 use warnings;
  1         2  
  1         34  
6 1     1   6 use re '/s';
  1         5  
  1         131  
7              
8             our $VERSION = '5999.000_014';
9              
10 1     1   652 use parent qw/App::Cmd::Command/;
  1         289  
  1         6  
11 1     1   918 use Pod::Usage;
  1         56039  
  1         322  
12              
13             sub description {
14 0     0 1   my ($self) = @_;
15 0           my ($file) = (ref $self) =~ s,::,/,gr;
16 0           my $usage;
17 0           open my $fh, '>', \$usage; ## no critic (RequireCheckedOpen)
18 0           pod2usage(-input => $INC{"$file.pm"}, -output => $fh, -exitval => 'NOEXIT', -verbose => 99, -sections => [qw/SYNOPSIS DESCRIPTION/]);
19 0           close $fh; ## no critic (RequireCheckedClose)
20 0           $usage =~ s/Usage:/Usage examples:/;
21 0           1 while chomp $usage;
22 0           $usage
23             }
24              
25             1;
26             __END__