Branch Coverage

blib/lib/URI/PackageURL/App.pm
Criterion Covered Total %
branch 25 118 21.1


line true false branch
33 0 16 unless &GetOptionsFromArray(\@args, \%options, ("help|h", "man", "v", "download-url", "repository-url", "validate", "quiet|q", "info=s", "list", "type=s", "namespace=s", "name=s", "version=s", "qualifiers|qualifier=s%", "subpath=s", "null|0", "format=s", "json", "yaml", "dumper", "env"))
64 0 16 if defined $options{'man'}
65 0 16 if defined $options{'help'}
67 0 16 if (defined $options{'v'})
87 0 16 if (defined $options{'info'})
91 0 16 if (defined $options{'list'})
95 1 15 if (defined $options{'type'})
108 0 1 if ($@)
113 0 1 defined $options{'null'} ? :
120 0 15 unless $purl_string
122 1 14 if defined $options{'json'}
123 0 15 if defined $options{'yaml'}
124 0 15 if defined $options{'dumper'}
125 0 15 if defined $options{'env'}
129 14 1 if ($options{'validate'})
131 0 14 unless ($options{'quiet'})
132 0 0 $purl ? :
135 7 7 $purl ? :
139 0 1 if ($@)
146 0 1 if ($options{'download-url'})
148 0 0 unless defined $purl_urls->{'download'}
150 0 0 defined $options{'null'} ? :
155 0 1 if ($options{'repository-url'})
157 0 0 unless defined $purl_urls->{'repository'}
159 0 0 $options{'null'} ? :
163 1 0 if ($options{'format'} eq "json")
168 0 0 if ($options{'format'} eq "dumper")
173 0 0 if ($options{'format'} eq "yaml")
175 0 0 if (eval { do { require YAML::XS } })
179 0 0 if (eval { do { require YAML } })
189 0 0 if ($options{'format'} eq "env")
233 0 0 if ($purl_urls)
234 0 0 if (defined $purl_urls->{'download'})
238 0 0 if (defined $purl_urls->{'repository'})
272 0 0 if ($definition->component_have_definition("namespace"))
276 0 0 if ($definition->component_have_definition("name"))
280 0 0 if ($definition->component_have_definition("version"))
284 0 0 if ($definition->component_have_definition("subpath"))
288 0 0 if (@{$definition->qualifiers_definition;})
307 0 0 unless (%{$definition->definition;})
325 0 0 if $have_ns
347 0 0 unless $definition->component_have_definition($component)
359 0 0 if ($requirement)
363 0 0 if ($permitted_characters)
367 0 0 if ($case_sensitive)
368 0 0 $case_sensitive ? :
371 0 0 if (@{$normalization_rules;})
384 0 0 if ($native_name)
390 0 0 if ($note)
395 0 0 if (@{$qualifiers_definition;})
404 0 0 if (my $requirement = $qualifier->{'requirement'})
408 0 0 if (my $native_name = $qualifier->{'native_name'})
412 0 0 if (my $default_value = $qualifier->{'default_value'})
424 0 0 if ($repository)
426 0 0 $repository->{'use_repository'} ? :
431 0 0 $repository->{'use_repository'} ? :
435 0 0 if (my $note = $repository->{'note'})
441 0 0 if (@{$examples;})
454 0 0 if ($note)