Branch Coverage

blib/lib/Container/Buildah.pm
Criterion Covered Total %
branch 27 128 21.0


line true false branch
65 0 5 if (exists $params{'debug'})
72 5 0 unless (exists $self->{'config'})
76 0 5 if (exists $params{'yaml_config'})
79 0 0 if (ref $in_config eq 'HASH') { }
0 0 elsif (ref $in_config eq 'ARRAY' and ref $in_config->[0] eq 'HASH') { }
92 5 0 if (exists $self->{'config'}{'basename'}) { }
96 0 5 if (exists $ENV{$timestamp_envname}) { }
129 0 5 unless &Container::Buildah::open('STDIN', '<', '/dev/null')
133 0 5 unless &Container::Buildah::open($self->{'oldstdout'}, '>&STDOUT')
135 0 5 unless &Container::Buildah::open($self->{'oldstderr'}, '>&STDERR')
160 0 0 ref $in_args[0] && ref $in_args[0] eq 'Container::Buildah' ? :
164 0 0 if ($debug > 0)
166 0 0 if (exists $cb->{'oldstdout'} and $cb->{'oldstdout'}->fileno != CORE::fileno STDERR)
178 0 30 if (ref $cb ne 'Container::Buildah')
184 30 0 if (ref $in_args[0] eq 'HASH')
191 0 30 if ($debug >= $level)
196 0 0 if (exists $params{'name'} and defined $params{'name'}) { }
200 0 0 if ($caller eq '(eval)') { }
206 0 0 if (exists $params{'label'} and defined $params{'label'})
211 0 0 defined $_ ? :
213 0 0 if (exists $cb->{'oldstderr'} and $cb->{'oldstderr'}->fileno != CORE::fileno STDERR)
228 2 8 if (ref $value eq 'ARRAY')
258 9 0 ref $class_or_obj ? :
261 1 8 unless (@path)
272 6 0 if (exists $node->{$subnode} and ref $node->{$subnode} eq 'HASH') { }
280 7 1 if (exists $node->{$key})
281 0 7 if (ref $node->{$key} and ref $node->{$key} ne 'ARRAY')
288 2 5 if (ref $node->{$key} eq 'ARRAY') { }
304 0 0 ref $class_or_obj ? :
309 0 0 unless (exists $cb->{'config'}{$key})
315 0 0 if (@missing)
342 0 0 if ($arch eq 'arm')
344 0 0 if (/ ^ CPU \s architecture \s* : \s* (.*) $ /ux)
345 0 0 if ($1 eq '7')
360 0 10 if ($got_type ne 'ARRAY')
361 0 0 $got_type ? :
364 1 15 unless (defined $array_ref->[$i])
365 1 1 defined $_ ? :
381 0 0 if ($xc)
382 0 0 if (ref $xc eq 'autodie::exception') { }
0 0 elsif (ref $xc) { }
410 0 0 if (ref $stages ne 'HASH')
411 0 0 ref $stages ? :
423 0 0 if (exists $stages->{$stage}{$param})
424 0 0 if (ref $stages->{$stage}{$param} ne 'ARRAY')
426 0 0 ref $stages->{$stage}{$param} ? :
466 0 0 unless (-d $dir)
470 0 0 if (-l "$logdir_top/current")
478 0 0 $is_internal ? :
484 0 0 $is_internal ? :
485 0 0 unless eval { do { if ($is_internal) { my $func_deps = $stage->get_func_deps; my $func_exec = $stage->get_func_exec; unless (defined $func_exec) { croak("stage $name internal: func_exec not configured"); } ; if (ref $func_exec ne 'CODE') { confess("stage $name internal: func_exec is not a code reference - got " . ref($func_exec)); } ; if (defined $func_deps and ref $func_deps eq 'CODE') { $stage->status('func_deps'); &$func_deps($stage); } else { $stage->status('func_deps - skipped, not configured'); } ; $stage->status('consume'); $stage->consume; $stage->status('func_exec'); &$func_exec($stage); $stage->status('produce'); $stage->produce; } else { $stage->status('launch_namespace'); $stage->launch_namespace; } ; 1 } }
486 0 0 if ($is_internal) { }
496 0 0 unless (defined $func_exec)
499 0 0 if (ref $func_exec ne 'CODE')
505 0 0 if (defined $func_deps and ref $func_deps eq 'CODE') { }
524 0 0 $is_internal ? :
547 0 0 exists $init_config{'added_opts'} && ref $init_config{'added_opts'} eq 'ARRAY' ? :
549 0 0 if (exists $cmd_opts{'debug'})
555 0 0 unless (exists $init_config{'testing_skip_yaml'})
557 0 0 unless (defined $yaml_config)
559 0 0 if (-f $init_config{'basename'} . '.' . $suffix)
564 0 0 unless (defined $yaml_config)
576 0 0 if (exists $init_config{'required_config'} and ref $init_config{'required_config'} eq 'ARRAY')
582 0 0 if (exists $cmd_opts{'internal'}) { }