Branch Coverage

blib/lib/Console/Blackjack.pm
Criterion Covered Total %
branch 0 154 0.0


line true false branch
98 0 0 if $owner == 1 and $i == 1 and $hand->{'hide_down_card'}
101 0 0 $tmp_v > 9 ? :
103 0 0 if $method eq 1 and $v == 1 and $total < 11
107 0 0 if $method eq 1 and $total > 21
113 0 0 hand_value($player_hand, 1, 0) > 21 ? :
117 0 0 if scalar @{$cards;} != 2
118 0 0 if is_ace(@$cards[0]) and is_ten(@$cards[1])
120 0 0 is_ace(@$cards[1]) && is_ten(@$cards[0]) ? :
128 0 0 $player_hand->{'played'} || $player_hand->{'stood'} || 21 == hand_value($player_hand, 0, 0) || is_blackjack($player_hand->{'cards'}) || player_is_busted($player_hand) ? :
134 0 0 $player_hand->{'stood'} || player_is_busted($player_hand) || is_blackjack($player_hand->{'cards'}) ? :
161 0 0 if scalar @{$game->{'shoe'};} >= $total_cards
204 0 0 if $game->{'num_decks'} == @$spec[1] and $used > @$spec[0]
224 0 0 if $game->{'face_type'} == 2
235 0 0 if ($i == 1 and $dealer_hand->{'hide_down_card'}) { }
259 0 0 if ($player_hand->{'status'} == 3) { }
0 0 elsif ($player_hand->{'status'} == 2) { }
268 0 0 if not $player_hand->{'played'} and $index == $game->{'current_player_hand'}
271 0 0 if ($player_hand->{'status'} == 3) { }
0 0 elsif ($player_hand->{'status'} == 2) { }
0 0 elsif ($player_hand->{'status'} == 4) { }
272 0 0 player_is_busted($player_hand) ? :
275 0 0 is_blackjack($player_hand->{'cards'}) ? :
296 0 0 unless open TTY, "+
302 0 0 if $c =~ /$matcher/u
314 0 0 unless player_is_busted($player_hand) or is_blackjack($player_hand->{'cards'})
323 0 0 if is_blackjack($dealer_hand->{'cards'})
325 0 0 unless (need_to_play_dealer_hand($game))
345 0 0 if (is_blackjack($game->{'dealer_hand'}{'cards'}))
356 0 0 if (player_is_done($game, $player_hand))
381 0 0 if ($player_hand->{'played'} or $player_hand->{'stood'} or is_blackjack($player_hand->{'cards'}) or player_is_busted($player_hand) or 21 == hand_value($player_hand, 1, 0) or 21 == hand_value($player_hand, 0, 0))
391 0 0 if (not $player_hand->{'payed'} and player_is_busted($player_hand))
404 0 0 if $game->{'current_bet'} < 500
405 0 0 if $game->{'current_bet'} > 10000000
408 0 0 if $game->{'current_bet'} > $game->{'money'}
412 0 0 hand_value($dealer_hand, 1, 1) > 21 ? :
423 0 0 if $player_hand->{'payed'}
428 0 0 if ($dhb or $phv > $dhv) { }
0 0 elsif ($phv < $dhv) { }
430 0 0 if is_blackjack($player_hand->{'cards'})
471 0 0 if $tmp < 1
472 0 0 if $tmp > 8
514 0 0 if ($c eq 'n') { }
0 0 elsif ($c eq 't') { }
0 0 elsif ($c eq 'f') { }
0 0 elsif ($c eq 'b') { }
535 0 0 if $c eq "d"
537 0 0 if ($c eq 'b') { }
0 0 elsif ($c eq 'o') { }
0 0 elsif ($c eq 'q') { }
554 0 0 if $player_hand->{'stood'} or scalar @{$game->{'player_hands'};} >= 7
555 0 0 if $game->{'money'} < all_bets($game) + $player_hand->{'bet'}
558 0 0 @$cards == 2 && @$cards[0]->{'value'} == @$cards[1]->{'value'} ? :
564 0 0 if $game->{'money'} < all_bets($game) + $player_hand->{'bet'}
569 0 0 $player_hand->{'stood'} || scalar @{$player_hand->{'cards'};} != 2 || player_is_busted($player_hand) || is_blackjack($player_hand->{'cards'}) ? :
573 0 0 if (more_hands_to_play($game))
592 0 0 if (player_is_done($game, $player_hand))
605 0 0 if (player_is_done($game, $player_hand))
620 0 0 if (more_hands_to_play($game))
631 0 0 unless (player_can_split($game))
663 0 0 if (player_is_done($game, $this_hand))
679 0 0 if player_is_done($game, $player_hand)
686 0 0 if (player_can_hit($player_hand))
687 0 0 if (player_can_stand($player_hand))
688 0 0 if (player_can_split($game))
689 0 0 if (player_can_dbl($game))
695 0 0 if ($c eq 'h') { }
0 0 elsif ($c eq 's') { }
0 0 elsif ($c eq 'p') { }
0 0 elsif ($c eq 'd') { }
714 0 0 if ($c eq 'y') { }
0 0 elsif ($c eq 'n') { }
723 0 0 if need_to_shuffle($game)
747 0 0 if (dealer_upcard_is_ace(\%dealer_hand) and not is_blackjack(+(\%player_hand)->{'cards'}))
755 0 0 if (player_is_done($game, \%player_hand))
769 0 0 unless open my $fh, ">:encoding(UTF-8)", "bj.txt"
778 0 0 if (open my $fh, "<:encoding(UTF-8)", "bj.txt")
865 0 0 if $game{'quitting'}