Branch Coverage

blib/lib/GitHub/Crud.pm
Criterion Covered Total %
branch 3 298 1.0


line true false branch
42 0 0 if ($http and $http =~ /HTTP/u and $http =~ /200|201|404|409|422/u) { }
48 0 0 if ($ps == 0) { }
49 0 0 if (length $_ == 0) { }
55 0 0 if ($R->can($name)) { }
66 0 0 if (keys %can)
71 0 0 if (@data)
74 0 0 if (ref($p) =~ /hash/isu and my $c = $p->content)
186 0 0 if $@
202 0 0 $fileData ? :
219 0 0 if defined $s
221 0 0 if $r
232 0 0 unless $s
240 0 0 unless $gitHub->personalAccessToken
242 0 0 if (my $pat = $gitHub->personalAccessToken)
253 0 0 if $ref and $b
254 0 0 if not $ref and $b
273 0 0 if ($curl =~ /command not found/u)
309 0 0 unless $user
310 0 0 unless $repo
321 0 0 if $failed and $gitHub->confessOnFailure
324 0 0 if (not $failed and &reftype(scalar $r->data) =~ /array/iu)
334 0 0 unless ($gitHub->nonRecursive)
349 0 0 if ($d and length $d > 8)
353 0 0 if $h =~ /\A504b/iu
354 0 0 if $h =~ /\Ad0cf11e0/iu
355 0 0 if $h =~ /\Affd8ff/iu
356 0 0 if $h =~ /\A89504e470d0a1a0a/iu
357 0 0 if $h =~ /\A4D546864/iu
358 0 0 if $h =~ /\A49443340/iu
366 0 0 unless $user
367 0 0 unless $repo
368 0 0 unless $file
377 0 0 if $failed and $gitHub->confessOnFailure
379 0 0 if ($failed) { }
384 0 0 &specialFileData($d) ? :
393 0 0 unless ($data)
394 0 0 if ($File) { }
407 0 0 unless $user
408 0 0 unless $repo
409 0 0 unless $file
413 0 0 unless (&specialFileData($data))
420 0 0 if $File
423 0 0 $s ? :
436 0 0 if $b
449 0 0 $status == 201 ? :
0 0 $status == 200 ? :
450 0 0 $success ? :
451 0 0 if not $success and $gitHub->confessOnFailure
458 0 0 unless defined $sha
461 0 0 unless $user
462 0 0 unless $repo
471 0 0 $success ? :
472 0 0 if not $success and $gitHub->confessOnFailure
474 0 0 $success ? :
479 0 0 unless defined $data
482 0 0 unless $user
483 0 0 unless $repo
495 0 0 $status == 201 ? :
0 0 $status == 200 ? :
496 0 0 $success ? :
497 0 0 if not $success and $gitHub->confessOnFailure
499 0 0 $success ? :
504 0 0 unless defined $target
506 0 0 if (defined $r)
521 0 0 unless @file
531 0 0 if (not $gitHub->failed and &reftype(scalar $gitHub->response->data) =~ /array/iu)
533 0 0 if $_->path eq $gitHub->gitFile
543 0 0 if $gitHub->exists
547 0 0 if ($gitHub->exists)
549 0 0 if $gitHub->delete
559 0 0 unless $user
560 0 0 unless $repo
561 0 0 unless $file
566 0 0 unless $s
572 0 0 if $success
573 0 0 $success ? :
574 0 0 if not $success and $gitHub->confessOnFailure
575 0 0 $success ? :
584 0 0 unless $user
585 0 0 unless $repo
591 0 0 if not $success and $gitHub->confessOnFailure
600 0 0 unless $user
601 0 0 unless $repo
608 0 0 if not $success and $gitHub->confessOnFailure
616 0 0 unless my $data = $commits->data
623 0 0 unless -d $folder
626 0 0 unless $user
627 0 0 unless $repo
628 0 0 unless $bran
635 0 0 @files ? :
659 0 0 unless $success
667 0 0 unless my $s = $c{$b}
688 0 0 unless $success
710 0 0 if ($branch->status == 201) { }
0 0 elsif ($branch->status == 422) { }
724 0 0 unless $success
737 0 0 unless $user
738 0 0 unless $repo
746 0 0 $success ? :
747 0 0 if not $success and $gitHub->confessOnFailure
748 0 0 $success ? :
754 0 0 unless $user
755 0 0 unless $repo
756 0 0 unless $webUrl
759 0 0 $secret ? :
762 0 0 unless $webUrl =~ m[\Ahttps?://]u
777 0 0 $success ? :
778 0 0 if not $success and $gitHub->confessOnFailure
779 0 0 $success ? :
786 0 0 unless $user
793 0 0 $success ? :
794 0 0 if not $success and $gitHub->confessOnFailure
795 0 0 $success ? :
801 0 0 unless $user
802 0 0 unless $repo
803 0 0 $gitHub->private ? :
814 0 0 $success ? :
815 0 0 if not $success and $gitHub->confessOnFailure
816 0 0 $success ? :
834 0 0 unless $user
835 0 0 unless $repo
836 0 0 unless $body
837 0 0 unless $title
849 0 0 $success ? :
850 0 0 if not $success and $gitHub->confessOnFailure
852 0 0 $success ? :
869 0 0 if (my $r = $ENV{'GITHUB_REPOSITORY'})
877 0 0 unless ($g->personalAccessToken)
888 0 0 if (my $g = ¤tRepo())
898 0 0 unless $userid
899 0 0 unless $repository
900 0 0 unless $file
914 0 0 if (my $g = ¤tRepo())
922 0 0 unless -e $target
923 0 0 if (my $g = ¤tRepo())
931 0 0 if (my $g = ¤tRepo())
989 0 0 unless $userid
990 0 0 unless $repository
1007 0 0 unless $user
1008 0 0 unless $pat
1013 0 0 unless -e $file
1016 0 0 unless $pat eq $p->{'pat'}
1021 0 0 unless $user
1023 0 0 if (length($gitHub->personalAccessTokenFolder // accessFolder()) == 43)
1027 0 0 if ($ENV{'GITHUB_TOKEN'})
1035 0 0 unless my $a = $p->{'pat'}
2227 0 1 if eval "eof(${p}::DATA)"
2229 0 1 if $@
2231 0 1 if $@