Branch Coverage

blib/lib/Game/TextMapper/Apocalypse.pm
Criterion Covered Total %
branch 41 46 89.1


line true false branch
128 0 2 if $self->loglevel
141 42 358 if rand() < $self->settlement_chance
151 244 252 if ($coordinate % 2) { }
153 27 217 if $coordinate < $self->cols
154 20 224 if $coordinate >= ($self->rows - 1) * $self->cols
155 0 244 if $coordinate % $self->cols == 0
156 27 217 if $coordinate % $self->cols == $self->cols - 1
159 21 231 if $coordinate < $self->cols
160 23 229 if $coordinate >= ($self->rows - 1) * $self->cols
161 29 223 if $coordinate % $self->cols == 0
162 0 252 if $coordinate % $self->cols == $self->cols - 1
173 311 260 if $tiles->[$_]
199 18 158 unless @destinations
203 20 146 if ($rivers->[$next]) { }
18 128 elsif ($self->is_sink($next, $tiles)) { }
215 114 14 if $result
247 1 959 if defined $rivers->[$coordinate] and $rivers->[$coordinate] == 0
248 210 749 if grep {$_ == $coordinate;} @$river
249 612 191 unless $_ eq "mountain"
265 400 0 if $tiles->[$i]
268 170 214 if ref $river and @$river > 1
276 0 784 if @_ > 1
277 448 336 unless ref $_[0]