File Coverage

blib/lib/Parallel/Tiny/Test.pm
Criterion Covered Total %
statement 15 15 100.0
branch n/a
condition n/a
subroutine 5 5 100.0
pod 0 2 0.0
total 20 22 90.9


line stmt bran cond sub pod time code
1             package Parallel::Tiny::Test;
2 11     11   3751 use strict;
  11         22  
  11         231  
3 11     11   33 use warnings;
  11         66  
  11         231  
4 11     11   33 use File::Temp qw(tempfile);
  11         11  
  11         1122  
5              
6             sub new {
7 21     21 0 18299 my ( $fh, $filename ) = tempfile();
8 21         8770202 return bless( { tempfile => $fh, filename => $filename }, shift );
9             }
10              
11             sub run {
12 10     10 0 72 my $self = shift;
13 10         86 my $file = $self->{tempfile};
14 10         410 print $file 1;
15 10         610 close($file);
16             }
17              
18             1;
19