File Coverage

blib/lib/HTML/Shakan/Field/File.pm
Criterion Covered Total %
statement 15 15 100.0
branch n/a
condition n/a
subroutine 5 5 100.0
pod 0 1 0.0
total 20 21 95.2


line stmt bran cond sub pod time code
1             package HTML::Shakan::Field::File;
2 22     22   113 use strict;
  22         39  
  22         642  
3 22     22   104 use warnings;
  22         34  
  22         477  
4 22     22   103 use Mouse;
  22         36  
  22         123  
5             extends 'HTML::Shakan::Field::Input';
6              
7             has '+type' => (
8             default => 'file',
9             );
10              
11             sub field_filter {
12 6     6 0 13 my ($self, $form, $params) = @_;
13 6         109 $form->uploads->{$self->name} = FormValidator::Lite::Upload->new(
14             $form->request, $self->name,
15             );
16 6         65068 $params;
17             }
18              
19 22     22   8102 no Mouse;
  22         55  
  22         91  
20             __PACKAGE__->meta->make_immutable;
21             __END__