Branch Coverage

blib/lib/App/Sqitch/Command.pm
Criterion Covered Total %
branch 58 62 93.5


line true false branch
83 3 253 if $class eq "App::Sqitch::Command"
97 9 56 unless (eval "require $pkg; 1")
108 1 38 unless my $cmd = delete $p->{'command'}
109 3 35 unless my $pkg = $class->class_for($p->{'sqitch'}, $cmd)
149 33 16 unless $args and @{$args;}
153 2 14 unless &Getopt::Long::GetOptionsFromArray($args, \%opts, $class->options)
158 8 2 unless (my $nk = $k) =~ s/-/_/g
195 1 1 if ref $self eq "App::Sqitch::Command"
229 1 3 if $p{'target'}
237 128 48 unless $p{'no_changes'}
238 44 132 if ($p{'target'})
246 47 144 if (not $p{'no_changes'} and $target and -e $target->plan_file and $target->plan->contains($arg)) { }
39 105 elsif ($config->get('key', "target.$arg.uri") or 'URI'->new($arg)->isa('URI::db')) { }
21 84 elsif ($engines{$arg}) { }
7 77 elsif (-e $arg) { }
252 38 0 unless $seen{$target->name}++
257 21 0 unless $seen{$target->name}++
261 7 0 unless %target_for
263 6 1 if ($target_for{$arg}) { }
266 6 0 unless $seen{$target->name}++
278 58 7 unless $_
122 53 unless $p{'names'}
281 21 154 if (my(@unknown) = @{$rec{'unknown'};})
292 12 142 if ($p{'all'}) { }
64 78 elsif (not @targets) { }
294 4 8 if @targets
303 4 60 $self->sqitch->config->get('key', $key, 'as', 'bool') ? :
305 1 59 if $deftarget_err
315 113 49 if make_path($dir, {"error", \my $err})
318 160 2 unless my $diag = shift @{$err;}
321 1 1 if $path