Branch Coverage

lib/Dancer2/Plugin/OpenAPIRoutes.pm
Criterion Covered Total %
branch 1 96 1.0


line true false branch
21 0 1 if (%{'JSV::Compiler::';})
55 0 0 if not /^x-/
65 0 0 if ($mn == 1 and not exists $paths{$p})
67 0 0 if (@p > 2)
72 0 0 if ($m) { }
115 0 0 if ($http_methods_func_map{"${method}:$path_spec"})
117 0 0 if $mf
118 0 0 if $mm
120 0 0 if ($module_name eq '') { }
125 0 0 $http_methods_func_map{$func} ? :
126 0 0 if ($rfunc eq 'create' and $func eq 'post' and $path_spec =~ m[/\{[^/{}]*\}$])
135 0 0 unless $config->{'schema'}
138 0 0 if ($config->{'schema'} =~ /\.json/i) { }
0 0 elsif ($config->{'schema'} =~ /\.yaml/i) { }
144 0 0 if ($schema and 'HASH' eq ref $schema)
147 0 0 if ('HASH' eq ref $_ and exists $_->{'$ref'} and not ref $_->{'$ref'} and keys %$_ == 1)
154 0 0 if ('HASH' eq ref $rp) { }
171 0 0 if $parameter_spec =~ /^x-/
178 0 0 if ($in eq 'body') { }
0 0 elsif ($in eq 'header') { }
0 0 elsif ($in eq 'query') { }
0 0 elsif ($in eq 'path') { }
0 0 elsif ($in eq 'formData') { }
179 0 0 $required && !$ValidationCompiler ? :
200 0 0 if ($parameter_spec->{'type'} and $parameter_spec->{'type'} eq 'integer') { }
207 0 0 if ($parameter_spec->{'type'} and $parameter_spec->{'type'} eq 'file') { }
213 0 0 if ($src)
216 0 0 if ($ValidationCompiler) { }
218 0 0 if ($schema{'properties'}{$name}{'type'} and $schema{'properties'}{$name}{'type'} eq 'file')
222 0 0 if $required
224 0 0 if $required
227 0 0 if ($ValidationCompiler)
233 0 0 if ($mpath =~ /\(\?
243 0 0 if length $_[1] >= length $_[0]
246 0 0 if $a eq $b
247 0 0 if (&$ssc($a, $b))
250 0 0 if (&$ssc($b, $a))
269 0 0 if ($custom_map and 'HASH' eq ref $custom_map)
274 0 0 if $path_spec =~ /^x-/
278 0 0 if $method =~ /^x-/
281 0 0 if ($paths->{$path_spec}{$method}{'parameters'})
285 0 0 $method eq 'delete' ? :
333 0 0 if ($debug > 1)
337 0 0 if ($@)
348 0 0 if ($app->route_exists($route))
351 0 0 if $debug
353 0 0 if not $success_load or $@
356 0 0 unless $cref