Branch Coverage

blib/lib/Test/Clustericious/Cluster.pm
Criterion Covered Total %
branch 95 130 73.0


line true false branch
29 0 28 if (ref $_[0] and eval { do { $_[0]->isa('Test::Mojo') } }) { }
38 0 28 ref $_[0] ? :
41 0 28 $^O eq 'MSWin32' ? :
45 28 0 ref $args->{'lite_path'} ? :
76 39 6 if $self->{'t'} and @{$self->apps;} and not $self->{'stopped'}[-1]
113 3379 2 unless defined $data
125 0 2 unless -d "$home/lib"
144 64 6 if (defined $index) { }
171 0 0 if $self->{'auth_url'} and $self->{'auth_url'}
175 0 20 unless defined $self->{'apps'}[$i]
177 1 19 if $stopped
221 20 0 unless (defined $class)
223 20 0 if (eval ' require Clustericious::Config::Helpers; 1') { }
0 0 elsif (eval ' Clustericious::Config::Plugin; 1 ') { }
235 0 20 unless $class
264 0 20 if $caller ne 'main'
269 17 3 if -d "$home/lib"
281 31 3 unless (ref $item)
286 6 25 if (Mojo::Loader::data_section($caller, $fn))
292 9 25 if (ref $item eq 'ARRAY') { }
295 6 3 unless (ref $config)
298 1 5 unless -d "$home/etc"
313 0 34 $app_name =~ /\.psgi$/ ? :
324 34 0 unless (defined $app)
340 4 30 unless (defined $app)
342 1 3 if (my $script = Mojo::Loader::data_section($caller, "script/$app_name"))
345 1 0 unless -d "$home/script"
347 0 1 if (my $error = $@)
351 0 4 if (my $script = Mojo::Loader::data_section($caller, "script/$psgi_name"))
363 3 31 unless (defined $app)
367 2 9 if (not $app_name =~ /\.psgi$/ and $^O eq 'MSWin32' && -e "$dir/$app_name" || -x "$dir/$app_name")
371 0 2 if (my $error = $@)
376 0 9 if (-e "$dir/$psgi_name")
386 1 33 unless (defined $app)
388 1 0 if $first_try_error
393 33 1 if (defined $app)
396 12 22 if (eval { do { $app->isa('Clustericious::App') } })
398 0 12 if ($app->can('auth_ua'))
402 0 0 unless defined $self->{'auth_ua'}
408 12 22 if ($app and $app->isa('Clustericious::App'))
413 0 12 unless -d "$home/etc"
414 4 8 unless (-e $fn)
428 0 34 if defined $cb
434 7 13 if ($INC{'Clustericious/App.pm'})
437 7 0 if (not $@ and 'Clustericious::Client'->can('_mojo_user_agent_factory'))
445 20 0 if (defined $self->{'t'})
461 0 4 if (eval ' use Clustericious; 1 ' and not eval ' use Clustericious 0.9925; 1 ')
468 1 3 if ($self->{'auth_ua'} or $self->{'auth_url'}) { }
486 0 3 if (my $error = $@)
510 4 1 if (defined $app) { }
517 0 4 if $error
519 1 0 if ($index == $#{$self->apps;} and $self->{'t'})
531 4 1 if $ok
537 1 4 if $error
553 4 1 if (defined $app) { }
560 0 4 if (my $error = $@)
573 4 1 if $ok
575 1 0 if ($index == $#{$self->apps;} and $self->{'t'})
583 1 4 if $error
633 2 24 unless (ref $regex eq 'Regexp')
647 11 41 unless $name =~ /$regex/
651 28 13 unless (-d "$home/$dir")
656 39 2 unless (-f "$home/$dir/$basename")
674 1 5 unless eval { do { $app->isa('Clustericious::App') } }
676 1 4 unless ($client_class->can('new') or eval " require $client_class; $client_class->isa('Clustericious::Client') ")