File Coverage

blib/lib/Template/HTML.pm
Criterion Covered Total %
statement 22 22 100.0
branch 2 2 100.0
condition n/a
subroutine 6 6 100.0
pod 1 1 100.0
total 31 31 100.0


line stmt bran cond sub pod time code
1             package Template::HTML;
2              
3 2     2   51175 use strict;
  2         5  
  2         71  
4 2     2   10 use warnings;
  2         2  
  2         56  
5 2     2   10 use base qw(Template);
  2         5  
  2         3597  
6              
7             our $VERSION = '0.04';
8              
9 2     2   60357 use Template::HTML::Stash;
  2         6  
  2         51  
10 2     2   1046 use Template::HTML::Context;
  2         6  
  2         229  
11              
12             sub new {
13 3     3 1 1683 my $class = shift;
14              
15 3         9 my $config = $_[0];
16              
17 3 100       24 unless ( ref $config eq 'HASH' ) {
18 2         8 $config = { @_ };
19             }
20              
21 3         42 $config->{STASH} = Template::HTML::Stash->new($config);
22 3         112 $config->{CONTEXT} = Template::HTML::Context->new($config);
23              
24 3         6451 $class->SUPER::new($config);
25             }
26              
27             1;
28             __END__