File Coverage

blib/lib/constant/string.pm
Criterion Covered Total %
statement 16 16 100.0
branch 1 2 50.0
condition n/a
subroutine 5 5 100.0
pod n/a
total 22 23 95.6


line stmt bran cond sub pod time code
1             package constant::string;
2              
3 4     4   391250 use strict;
  4         9  
  4         161  
4 4     4   18 use warnings;
  4         12  
  4         325  
5 4     4   1959 use utf8;
  4         1012  
  4         19  
6 4     4   132 use constant ();
  4         10  
  4         549  
7              
8             our $VERSION = '2026.26';
9              
10             sub import {
11 4     4   55 my ($class, @args) = @_;
12 4         11 my $caller = caller;
13              
14 4         51 my %constants = map +( "${caller}::$_" => $_ ), @args;
15              
16 4 50       2429 constant->import( \%constants ) if %constants;
17              
18             }
19              
20             1;
21              
22             __END__