Branch Coverage

blib/lib/Geo/Converter/dms2dd.pm
Criterion Covered Total %
branch 51 58 87.9


line true false branch
55 1 25 unless defined $value
59 2 23 unless ($value =~ / \A [\s0-9NEWSnews+-] /msx)
63 2 23 if defined $first_char_invalid
69 3 20 if $Geo::Converter::dms2dd::EVAL_ERROR
76 2 18 if $Geo::Converter::dms2dd::EVAL_ERROR
79 9 9 if ($hemi =~ / [SsWw-] /msx)
102 2 16 if $Geo::Converter::dms2dd::EVAL_ERROR
124 0 23 if (not defined $deg) { }
1 22 elsif (scalar @nums > $MAX_DMS_NUM_COUNT) { }
131 19 4 if (defined $sec)
132 1 18 if (not $min =~ / \A $RE_INT \z/msx) { }
0 18 elsif ($sec < 0 or $sec > 60) { }
140 22 1 if (defined $min)
141 1 21 if (not $deg =~ / \A $RE_INT \z/msx) { }
0 21 elsif ($min < 0 or $min > 60) { }
155 3 20 if $msg
158 20 0 wantarray ? :
175 10 8 if ($is_lat // $hemi =~ / [SsNn] /msx) { }
7 1 elsif ($is_lon // $hemi =~ / [EeWw] /msx) { }
0 1 elsif ($dd < $MIN_VALID_DD or $dd > $MAX_VALID_DD) { }
176 1 9 if ($is_lon) { }
1 8 elsif (abs $dd > $MAX_VALID_LAT) { }
184 0 7 if ($is_lat) { }
0 7 elsif (abs $dd > $MAX_VALID_LON) { }
194 2 16 if $msg
206 14 6 if ($value =~ / \A ( $RE_HEMI | [-] )/msx)
210 7 13 if ($value =~ / ( $RE_HEMI ) \z /msx)
213 2 5 if defined $hemi and defined $hemi_end
218 1 17 unless (defined $hemi)