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   857 use 5.014000;
  1         4  
4 1     1   6 use strict;
  1         2  
  1         27  
5 1     1   6 use warnings;
  1         2  
  1         43  
6 1     1   6 use re '/s';
  1         7  
  1         87  
7              
8             our $VERSION = '5999.000_015';
9              
10 1     1   742 use parent qw/App::Cmd::Command/;
  1         280  
  1         6  
11 1     1   938 use Pod::Usage;
  1         53013  
  1         383  
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__