Branch Coverage

blib/lib/MVC/Neaf/CLI.pm
Criterion Covered Total %
branch 21 42 50.0


line true false branch
91 1 4 if (grep {$_ eq "--list";} @ARGV)
94 1 3 if (grep {$_ eq "--help";} @ARGV)
99 1 2 if (grep {$_ =~ /^--listen/;} @ARGV)
111 0 2 unless &GetOptions("post", sub { $test{'method'} = "POST"; } , "method=s", \$test{'method'}, "upload=s\@", \$test{'upload'}, "cookie=s\@", \$test{'cookie'}, "header=s\@", \$test{'head'}, "view=s", \$test{'view'})
140 1 1 if $test{'method'}
143 0 2 if $test{'upload'} and $test{'method'} ne "POST"
145 0 2 if (my $up = delete $test{'upload'})
147 0 0 unless /^(\S+?)=(.+)$/
150 0 0 unless open my $fd, "<", $file
159 0 2 if (my $cook = delete $test{'cookie'})
161 0 0 unless /^(\S+?)=(.*)$/
167 2 0 unless delete $test{'head'}
0 2 if (my(@head) = @{[] unless delete $test{'head'};})
169 0 0 unless /^([^=]+)=(.*)$/
175 0 2 if (@rest)
176 0 0 $path =~ /\?/ ? :
180 1 1 if (my $view = delete $test{'view'})
242 6 0 if (my $rex = $route->{'path_info_regex'})
244 0 6 if $rex =~ /^\(.*?\((.*)\).*?\)$/
249 0 6 if $param
252 0 6 if $route->{'description'}