Branch Coverage

blib/lib/Device/Quasar3108.pm
Criterion Covered Total %
branch 2 82 2.4


line true false branch
32 1 0 unless defined $portname
33 1 0 unless defined $timeout
42 0 0 unless $port->can_ioctl
44 0 0 unless $port->can_status
46 0 0 unless $port->can_write_done
51 0 0 unless $port->baudrate(9600)
52 0 0 unless $port->parity('none')
53 0 0 unless $port->databits(8)
54 0 0 unless $port->stopbits(1)
55 0 0 unless $port->handshake('none')
57 0 0 unless $port->write_settings
102 0 0 if ($ok eq '#') { }
111 0 0 unless defined $num
115 0 0 if ($ok eq '#') { }
124 0 0 unless defined $num
128 0 0 if ($ok eq '#') { }
136 0 0 unless defined $num
140 0 0 if ($ok eq '#') { }
149 0 0 unless defined $num
152 0 0 unless defined $period
155 0 0 unless $self->relay_on($num)
157 0 0 unless $self->relay_off($num)
168 0 0 unless defined $value
172 0 0 if ($ok eq '#') { }
181 0 0 unless defined $num
188 0 0 if ($num == 0) { }
193 0 0 if ($ok ne '#')
203 0 0 unless defined $num
210 0 0 if ($num == 0) { }
215 0 0 if ($ok ne '#')
231 0 0 unless $string =~ /\r\n?$/
247 0 0 if ($@)
248 0 0 unless $@ =~ /Timed out./
256 0 0 if ($$self{'debug'})
275 0 0 unless defined $bytes_wanted
288 0 0 if $string =~ /#$/ or $bytes >= $bytes_wanted
294 0 0 if ($@)
295 0 0 unless $@ =~ /Timed out./
302 0 0 if ($$self{'debug'})
310 0 0 if ($bytes_wanted == 1) { }
323 0 0 unless $$self{'port'}->close