Branch Coverage

blib/lib/Games/Solitaire/Verify/State.pm
Criterion Covered Total %
branch 75 86 87.2


line true false branch
94 0 266 unless ($str =~ /\A(Foundations:[^\n]*)\n/gms)
110 0 266 unless ($str =~ /\G(Freecells:[^\n]*)\n/gms)
119 2 2126 unless ($str =~ /\G(:[^\n]*)\n/gms)
149 0 272 unless (defined $params)
169 9 272 if ($variant eq 'custom') { }
191 272 9 if (exists $args->{'string'})
282 328 3448 unless ($self->get_column($idx)->len)
296 1 6 $variant eq 'custom' ? :
325 13 212 if ($self->_variant_params->empty_stacks_filled_by eq 'kings')
327 2 11 if ($card->rank != 13)
347 128 0 $sbb eq 'suit' ? :
977 128 $sbb eq 'alt_color' ? :
317 1105 $rules eq 'simple_simon' ? :
354 3 1419 if ($verdict)
371 3 1422 if ($parent->rank != $child->rank + 1)
381 3 1419 if (my $ret = $self->_is_matching_color($parent, $child))
394 225 863 $self->get_column($col_idx)->len == 0 ? :
403 451 0 defined $args->{'to_empty'} ? :
420 451 37 $self->_variant_params->empty_stacks_filled_by eq 'any' ? :
127 488 $self->_variant_params->sequence_move eq 'unlimited' ? :
443 1 561 if ($self->_can_put_on_top($parent, $child))
454 14 240 $parent->suit ne $child->suit ? :
254 307 $rules eq 'simple_simon' ? :
477 2458 0 if (my $method = $self->can('_mv_' . $move->source_type . '_to_' . $move->dest_type)) { }
506 656 1 if (defined $f_idx) { }
528 1 6 if ($rules ne 'simple_simon')
540 0 6 if ($verdict)
545 1 5 if ($num_seq_components != 1)
558 5 0 if (defined $f_idx) { }
583 1 588 unless ($self->get_column($col_idx)->len)
590 1 587 if (defined $self->get_freecell($fc_idx))
616 1 619 if ($source_len < $num_cards)
624 1 618 if (my $verdict = $self->_is_sequence_in_column($source, $num_cards, \$num_seq_components))
633 3 615 if (my $verdict = $self->_can_put_on_column($dest, $sc->pos($source_len - $num_cards)))
645 3 612 if ($num_seq_components > $self->_calc_max_sequence_move({'to_empty', $dc->len == 0}))
672 1 113 unless (defined $card)
685 112 1 if (defined $f_idx) { }
709 1 470 unless (defined $card)
715 4 466 if (my $verdict = $self->_can_put_on_column($col_idx, $card))
737 0 832 if ($card->rank > $MAX_RANK)
743 0 832 if (++$found->{$s} > 1)
753 14 50 if (defined $card)
785 0 16 if (scalar keys %$found != $MAX_RANK * 4)