File Coverage

blib/lib/Petal/Utils/LowerCase.pm
Criterion Covered Total %
statement 23 23 100.0
branch n/a
condition 1 3 33.3
subroutine 7 7 100.0
pod 0 1 0.0
total 31 34 91.1


line stmt bran cond sub pod time code
1             package Petal::Utils::LowerCase;
2              
3 5     5   29 use strict;
  5         29  
  5         191  
4 5     5   26 use warnings::register;
  5         6  
  5         621  
5              
6 5     5   28 use Carp;
  5         9  
  5         345  
7              
8 5     5   30 use base qw( Petal::Utils::Base );
  5         12  
  5         416  
9              
10 5     5   26 use constant name => 'lowercase';
  5         9  
  5         281  
11 5     5   28 use constant aliases => qw( lc );
  5         9  
  5         1122  
12              
13             our $VERSION = ((require Petal::Utils), $Petal::Utils::VERSION)[1];
14             our $REVISION = (split(/ /, ' $Revision: 1.2 $ '))[2];
15              
16             sub process {
17 1     1 0 28845 my $class = shift;
18 1         3 my $hash = shift;
19 1   33     5 my $args = shift || confess( "'lowercase' expects a variable (got nothing)!" );
20 1         6 my $result = $hash->fetch($args);
21 1         178 return lc($result);
22             }
23              
24             1;