Branch Coverage

blib/lib/Catalyst/Controller/AutoAssets/Handler.pm
Criterion Covered Total %
branch 39 70 55.7


line true false branch
131 4 12 if $self->is_current_request_arg(@args)
135 0 12 if $self->allow_static_requests and $self->static_alias eq $sha1
145 2 3 $arg eq $self->current_alias ? :
176 0 12 if ($self->use_etags and $self->client_current_etag($c, $arg, @args)) { }
192 0 0 $client_etag && $client_etag eq $etag ? :
251 12 3 if ($inc->is_dir) { }
257 27 14 $self->_valid_include_file($child) ? :
264 3 0 $self->_valid_include_file($inc) ? :
297 14 30 $file->is_dir || $self->include_regex && !($file =~ $self->_include_regexp) || $self->exclude_regex && $file =~ $self->_exclude_regexp ? :
308 26 6 -f $self->built_file ? :
326 6 0 if $sha1
332 3 20 unless -f $self->fingerprint_file
339 0 3 unless my $fingerprint = shift()
345 0 3 unless my $fingerprint = $self->calculate_fingerprint(@_)
351 0 23 unless my $last = $self->last_fingerprint_calculated
352 23 0 if $self->max_fingerprint_calc_age == 0
353 0 0 if time - $last < $self->max_fingerprint_calc_age
372 3 0 unless $self->persist_state
382 0 0 unless -f $self->persist_state_file
386 0 0 if ($self->_valid_state_data($data))
404 0 0 $self->_module_version eq $$data{'_module_version'} && Dumper($self->_build_params) eq Dumper($$data{'_build_params'}) ? :
420 23 3 $self->inc_mtimes && $self->built_mtime && $$d{'inc_mtimes'} && $$d{'built_mtime'} && $self->inc_mtimes eq $$d{'inc_mtimes'} && $self->built_mtime eq $$d{'built_mtime'} && $self->fingerprint_calc_current ? :
454 23 3 unless $self->_build_required($opt)
477 0 3 if $self->_app->debug
498 0 3 if ($fingerprint and $cur_fingerprint and $cur_fingerprint eq $fingerprint)
510 0 3 unless my $fd = $self->built_file->openw
513 2 1 if $fd->opened
527 0 6 ref $_[0] eq 'ARRAY' ? :
531 0 19 unless my $fh = $file->openr
574 0 3 unless sysopen $fh, $fname, 194, 420 or sysopen $fh, $fname, 2
579 0 3 unless &try(sub { fcntl $fh, 2, 1; } )
586 3 0 if flock $fh, 6
587 0 0 if &Time::HiRes::time() >= $deadline
593 0 3 unless syswrite $fh, $data, length $data
594 0 3 unless truncate $fh, length $data