Branch Coverage

blib/lib/Git/Archive.pm
Criterion Covered Total %
branch 41 52 78.8


line true false branch
13 16 0 ref $_[0] eq 'HASH' ? :
25 1 15 unless ($$args{'msg'})
28 1 2 unless ($$args{'files'} or $$args{'all_tracked'} or $$args{'all_dirty'})
31 0 14 unless (can_run('git'))
38 2 12 unless ($repo)
41 1 11 if ($repo->run('diff', '--cached', '--name-only'))
46 0 11 unless ($repo->run('config', 'user.email'))
49 0 11 unless ($repo->run('config', 'user.name'))
55 1 10 unless (@{$files;})
60 2 8 if $$args{'use_remote'}
61 1 9 if $do_remote
64 0 9 if $$args{'success'}
72 5 4 unless (ref $$args{'files'} eq 'ARRAY')
83 1 13 unless (-e $$args{'git_dir'})
87 1 12 unless (-e $$args{'git_dir'} . '/.git')
93 0 12 if (my $sudo = $$args{'sudo'})
97 12 0 unless ($@)
109 9 2 if ($$args{'files'}) { }
1 1 elsif ($$args{'all_tracked'}) { }
1 0 elsif ($$args{'all_dirty'}) { }
114 2 7 if ($$args{'check_all_staged'})
116 1 1 unless (@staged == @{$files;})
130 0 1 unless (@staged = grep({not $_ =~ /^\?\?/;} @status))
140 0 1 unless (@status)
160 1 1 if ($pull =~ /Automatic merge failed/)
170 0 1 if ($push =~ /\[rejected\]/)