Branch Coverage

blib/lib/MooX/Options/Descriptive/Usage.pm
Criterion Covered Total %
branch 71 100 71.0


line true false branch
89 0 94 if (defined $self->{'target'} and defined(my $sub_commands_options = $self->{'target'}->_options_sub_commands))
97 94 0 unless @$sub_commands
112 84 0 defined $self->{'target'} ? :
116 84 0 defined $self->{'target'} ? :
124 86 467 if ($opt->{'desc'} eq 'spacer')
132 78 389 if defined $format
134 10 457 if defined $options_data{$opt->{'name'}}{'json'}
140 1 466 defined $short ? :
358 109 length $opt->{'name'} > 1 ? :
78 389 defined $format_doc_str ? :
142 105 362 if $max_spec_length < length $spec
151 467 86 if (length $spec) { }
192 10 0 defined $self->{'target'} ? :
196 10 0 defined $self->{'target'} ? :
201 12 52 if ($opt->{'desc'} eq 'spacer')
209 3 49 if defined $format
211 2 50 if defined $options_data{$opt->{'name'}}{'json'}
215 0 52 defined $short ? :
32 20 length $opt->{'name'} > 1 ? :
3 49 defined $format_doc_str ? :
219 0 52 unless defined $opt_data
227 0 52 defined $opt_data->{'long_doc'} ? :
245 3 0 defined $self->{'target'} ? :
249 3 0 defined $self->{'target'} ? :
252 0 3 unless defined $prog_name
255 0 3 if (defined $self->{'target'} and defined(my $sub_commands_options = $self->{'target'}->_options_sub_commands))
267 0 3 if (defined(my $description = $options_config{'description'}))
277 0 3 if (defined(my $synopsis = $options_config{'synopsis'}))
285 3 15 if ($opt->{'desc'} eq 'spacer')
293 3 12 if defined $format
296 2 13 if defined $options_data{$opt->{'name'}}{'json'}
299 10 5 length $opt->{'name'} > 1 ? :
300 0 15 defined $short ? :
3 12 defined $format_doc_str ? :
308 0 15 unless defined $opt_data
311 0 15 defined $opt_data->{'long_doc'} ? :
315 0 3 if (@$sub_commands)
319 0 0 if ($sub_command->{'command'}->can('_options_config') and defined(my $desc = {$sub_command->{'command'}->_options_config}->{'description'})) { }
342 3 0 if (defined(my $authors = $options_config{'authors'}))
343 0 3 if (not ref $authors and length $authors)
346 0 3 if (@$authors)
365 2 0 defined $self->{'target'} ? :
369 0 2 unless defined $prog_name
373 2 12 if ($opt->{'desc'} eq 'spacer')
379 4 8 if defined $format
381 0 12 if defined $options_data{$opt->{'name'}}{'json'}
386 10 2 length $opt->{'name'} > 1 ? :
4 8 defined $format_doc_str ? :
389 2 12 $_ eq '' ? :
416 0 0 $self ? :