Branch Coverage

blib/lib/Config/Properties/Commons.pm
Criterion Covered Total %
branch 85 140 60.7


line true false branch
52 1 5 if (defined $options{'load_file'})
69 0 6 unless defined $from
75 5 1 unless (ref $from)
83 0 5 unless $file and -f $file
90 0 5 if $options{'cache_files'} and $$self{'_seen_files'}{$file}
120 26 4 unless exists $$self{'_properties'}{$key}
127 0 0 unless exists $$self{'_properties'}{$key}
146 23 7 ref $values ? :
148 4 26 if (defined $old_value) { }
150 0 4 ref $old_value ? :
153 1 25 if ($$self{'_options'}{'force_value_arrayref'}) { }
157 3 22 if (scalar @new_values > 1) { }
162 0 30 unless defined $save
176 0 9 if (defined $prefix) { }
177 0 0 unless defined $sep
189 9 0 if wantarray
199 0 0 if (defined $prefix)
209 0 0 if scalar @keys
217 0 0 if defined $val
226 0 7 unless defined $key and hascontent($key)
228 7 0 unless exists $$self{'_properties'}{$key}
244 0 7 unless $self->delete_property(@args)
245 0 7 unless $self->add_property(@args)
271 0 1 unless defined $to
339 8 8 if (@args)
340 3 5 if (ref $args[0] eq 'HASH') { }
535 17 41 if (exists $option_aliases{$_opt}) { }
571 6 0 $$in{'lines'} ? :
572 6 0 $$in{'options'} ? :
575 0 6 unless @lines
578 0 6 if ($lines[0] =~ /^\x{FEFF}/x)
590 14 36 unless hascontent($line)
593 13 23 if $line =~ /^\s*(?:\#|\!)/x
602 2 21 if ($line =~ /(?
609 0 2 unless hascontent($_wline)
612 2 0 unless $_wline =~ /(?
640 0 23 unless (defined $key and hascontent($key))
643 2 21 unless defined $value and hascontent($value)
652 0 23 unless defined $key and defined $value and hascontent($key)
656 21 2 if (hascontent($value)) { }
657 21 0 if (defined $options{'token_delimiter'}) { }
673 23 0 if ($options{'interpolation'}) { }
685 2 21 if ($options{'process_includes'} and $key eq $options{'include_keyword'})
690 0 2 unless $_basedir
691 1 1 if defined $options{'includes_basepath'}
697 0 2 if ('File::Spec'->file_name_is_absolute($_file)) { }
706 0 2 if ($_file eq $$self{'_current_file'}{'name'})
746 0 2 unless (exists $$self{'_properties'}{$key})
754 0 2 if (ref $def_key) { }
757 0 0 if scalar @{$def_key;} > 1
760 0 0 if ($options{'force_value_arrayref'})
769 0 2 unless defined $int_key
800 0 3 if $max_prop_len + $sep_len + 4 >= $options{'save_wrapped_len'}
806 0 14 unless defined $props{$key}
808 0 14 unless defined $value
812 5 9 if (ref $value) { }
813 0 5 unless ref $value eq 'ARRAY'
825 0 19 unless defined $_rvt
826 19 0 if (defined $options{'token_delimiter'}) { }
837 5 9 if ($options{'save_combine_tokens'}) { }
838 0 5 unless defined $options{'token_delimiter'}
844 5 0 unless $_delim =~ /\s+$/x
850 5 0 if ($do_wrap)
868 3 6 if (scalar @value_tokens > 1)
869 0 3 unless $out_str =~ /\n{2,}/mx
876 12 0 if ($do_wrap) { }
894 3 6 if (scalar @value_tokens > 1)
957 0 19 unless defined $delim
958 0 19 unless hascontent($delim)
959 1 18 unless hascontent($val)