File Coverage

blib/lib/WebServer/DirIndex/HTML.pm
Criterion Covered Total %
statement 9 9 100.0
branch n/a
condition n/a
subroutine 3 3 100.0
pod n/a
total 12 12 100.0


line stmt bran cond sub pod time code
1             package WebServer::DirIndex::HTML; # For cpanm :-(
2              
3 3     3   115205 use strict;
  3         8  
  3         127  
4 3     3   18 use warnings;
  3         7  
  3         231  
5 3     3   564 use Feature::Compat::Class;
  3         526  
  3         20  
6              
7             our $VERSION = '0.1.4';
8              
9             class WebServer::DirIndex::HTML {
10              
11             field $icons :param = 0;
12              
13             field $_file_html = <<'FILE';
14            
15             %s
16             %s
17             %s
18             %s
19            
20             FILE
21              
22             field $file_html_icons :reader = <<'FILE';
23            
24            
25             %s
26             %s
27             %s
28             %s
29            
30             FILE
31              
32             field $_dir_html = <<'DIR';
33            
34            
35             %s
36            
37            
40            
41            
42            

%s

43            
44            
45            
46            
47             Name
48             Size
49             Type
50             Last Modified
51            
52            
53            
54             %s
55            
56            
57            
58            
59            
60             DIR
61              
62             field $dir_html_icons :reader = <<'DIR';
63            
64            
65             %s
66            
67            
68            
71            
72            
73            

%s

74            
75            
76            
77            
78            
79             Name
80             Size
81             Type
82             Last Modified
83            
84            
85            
86             %s
87            
88            
89            
90            
91            
92             DIR
93              
94             method file_html { return $icons ? $file_html_icons : $_file_html }
95             method dir_html { return $icons ? $dir_html_icons : $_dir_html }
96             }
97              
98             1;
99              
100             __END__