Branch Coverage

blib/lib/Getopt/optparse.pm
Criterion Covered Total %
branch 12 50 24.0


line true false branch
47 1 0 if (&Scalar::Util::reftype($optvals) eq 'HASH') { }
48 0 1 unless ($optvals->{'dest'})
70 0 1 if ($self->{'cmdline'} =~ /--help\s+/ or $self->{'cmdline'} =~ /-h\s+/)
76 1 0 if ($self->{'parser'}{$key}{'dest'})
79 1 0 if ($parser->{'default'})
84 0 1 if ($parser->{'action'} eq "count")
89 0 1 if ($parser->{'action'} eq 'store_true') { }
90 0 0 if ($self->{'cmdline'} =~ /$key\s+/) { }
98 0 1 unless ($parser->{'default'})
103 0 1 if ($parser->{'action'} eq "append")
108 0 1 if ($parser->{'action'} eq "count")
109 0 0 if (my(@matches) = $self->{'cmdline'} =~ /$key\s+/g)
117 0 1 if (my(@matches) = $self->{'cmdline'} =~ /$key=(.*?)\s+/g)
118 0 0 if ($parser->{'action'} eq 'append') { }
124 0 0 unless ($matches[0] =~ /^-/)
145 0 1 if ($self->{'parser'}{$key}{'callback'})
166 0 0 if ($self->{$val}{$key}{'action'} eq "count")
169 0 0 if ($self->{$val}{$key}{'action'} eq "append")
173 0 0 if ($self->{$val}{$key}{'dest'} and $self->{$val}{$key}{'action'} ne "store_true")
176 0 0 if ($length > $max_length{'1'})
184 0 0 if ($key =~ /^--\w+/) { }
0 0 elsif ($key =~ /^-\w+/) { }
209 0 0 if ($self->{'parser'}{$key}{'action'} eq "count")
212 0 0 if ($self->{'parser'}{$key}{'action'} eq "append")
216 0 0 if ($self->{'parser'}{$key}{'dest'} and $self->{'parser'}{$key}{'action'} ne 'store_true') { }