Branch Coverage

blib/lib/Net/RCON/Minecraft.pm
Criterion Covered Total %
branch 40 40 100.0


line true false branch
42 1 32 if $s->connected
44 2 30 unless length $s->password
46 1 29 unless $s->_socket('IO::Socket::IP'->new('PeerAddr', $s->host, 'PeerPort', $s->port, 'Proto', 'tcp'))
61 5 23 unless $type == 2 and $id == $res_id
63 1 27 if $res_id == -1
64 3 24 if $type != 2
65 1 23 if $id != $res_id
66 1 22 if length $payload
73 10 3 if $s->_socket and $s->_socket->connected
77 6 31 if $_[0]->_socket
82 1 15 unless length $command
93 1 30 if ($id != $res_id)
100 1 29 if $type != 0
102 13 16 if $payload eq sprintf('Unknown request %x', $nonce)
126 1 61 if $size < 10
131 1 59 unless s/\0\0$//
144 124 3 if ($s->_select->can_read($s->timeout)) { }
147 1 123 unless defined $read
161 2 59 unless defined $payload
164 1 60 if $@