Branch Coverage

blib/lib/Lang/Go/Mod.pm
Criterion Covered Total %
branch 77 88 87.5


line true false branch
40 17 60 if $line =~ /^\s*$/x
41 3 57 if ($excludes)
42 1 2 if ($line =~ /^\s*[)]\s*$/x) { }
1 1 elsif ($line =~ /\s*(\S+)\s+(\S+)/x) { }
46 1 0 unless defined $m->{'exclude'}{$1}
54 4 53 if ($replaces)
55 1 3 if ($line =~ /^\s*[)]\s*$/x) { }
2 1 elsif ($line =~ /^\s*(\S+)\s+=>\s+(\S+)\s*$/x) { }
60 0 2 if defined $m->{'replace'}{$1}
68 5 48 if ($requires)
69 1 4 if ($line =~ /^\s*[)]\s*$/x) { }
3 1 elsif ($line =~ /^\s*(\S+)\s+(\S+).*$/x) { }
74 0 3 if defined $m->{'require'}{$1}
82 3 45 if ($retracts)
83 1 2 if ($line =~ /^\s*[)]\s*$/x) { }
2 0 elsif ($line =~ /^\s*(\S+)(.*)$/x) { }
88 0 2 unless defined $retract
91 0 2 if defined $m->{'retract'}{$retract}
101 12 33 if ($line =~ /^module\s+(\S+)$/x) { }
12 21 elsif ($line =~ /^go\s+(\S+)$/x) { }
2 19 elsif ($line =~ /^exclude\s+[(]\s*$/x) { }
2 17 elsif ($line =~ /^replace\s+[(]\s*$/x) { }
2 15 elsif ($line =~ /^require\s+[(]\s*$/x) { }
1 14 elsif ($line =~ /^retract\s+[(]\s*$/x) { }
3 11 elsif ($line =~ /^exclude\s+(\S+)\s+(\S+)\s*$/x) { }
1 10 elsif ($line =~ /^replace\s+(\S+)\s+=>\s+(\S+)\s*$/x) { }
1 9 elsif ($line =~ /^require\s+(\S+)+\s+(\S+).*$/x) { }
2 7 elsif ($line =~ /^retract\s+(.+)/x) { }
1 6 elsif ($line =~ m[^\s*//.*$]mx) { }
134 2 1 unless defined $m->{'exclude'}{$1}
141 0 1 if defined $m->{'replace'}{$1}
148 0 1 if defined $m->{'require'}{$1}
155 0 2 unless defined $retract
158 0 2 if defined $m->{'retract'}{$retract}
172 1 3 unless defined $m->{'module'}
173 1 2 unless defined $m->{'go'}
191 11 11 if ($retract =~ /^\s*\[(.+?)\](.*)$/x) { }
11 0 elsif ($retract =~ /^\s*(\S+)(.*)$/x) { }
200 1 19 unless $version =~ /\S+/x
203 3 7 if $count != 2
206 5 2 if ($rest =~ /\S/x)
207 2 3 unless $rest =~ m[^\s+//]ox
216 9 2 if ($rest =~ /\S/x)
217 6 3 unless $rest =~ m[^\s+//]ox