Branch Coverage

blib/lib/Protocol/IRC/Client.pm
Criterion Covered Total %
branch 55 70 78.5


line true false branch
89 1 8 unless defined $value
93 2 7 if ($name eq 'PREFIX') { }
2 5 elsif ($name eq 'CHANMODES') { }
1 4 elsif ($name eq 'CASEMAPPING') { }
1 3 elsif ($name eq 'CHANTYPES') { }
96 0 2 unless my($prefix_modes, $prefix_flags) = $prefix =~ /^\(([a-z]+)\)(.+)$/i
218 10 7 if ($effect eq 'more')
229 5 2 if ($effect eq 'done' and my $code = $self->can("prepare_gatehints_$gate"))
240 1 6 if ($futures = $self->{'Protocol_IRC_gate_futures'}{$gate}{$target} and @$futures)
242 1 0 if ($effect eq 'done') { }
250 0 7 if $self->invoke("on_gate_${effect}_$gate", $message, \%hints, $data)
251 0 7 if $self->invoke("on_gate_$effect", $gate, $message, \%hints, $data)
252 7 0 if $self->invoke('on_gate', $effect, $gate, $message, \%hints, $data)
254 6 1 if ($effect eq 'done')
255 0 6 if $self->invoke("on_message_$gate", $message, \%hints)
256 6 0 if $self->invoke('on_message', $gate, $message, \%hints)
328 0 3 unless my($flag, $nick) = $name =~ /$re/
428 2 2 if ($h->{'whois'} eq 'channels')
429 1 1 if ($channels)
524 0 1 if $self->invoke("on_message_cap_$verb", $message, \%hints)
525 1 0 if $self->invoke('on_message_cap', $verb, $message, \%hints)
585 7 22 if $modechar eq '+'
586 6 16 if $modechar eq '-'
595 2 14 if (index($listmodes, $modechar) > -1) { }
2 12 elsif (index($argmodes, $modechar) > -1) { }
4 8 elsif (index($argsetmodes, $modechar) > -1) { }
3 5 elsif (index($boolmodes, $modechar) > -1) { }
5 0 elsif (my $flag = $self->prefix_mode2flag($modechar)) { }
597 2 0 if $sense != 0
601 2 0 if $sense != 0
605 2 2 if $sense > 0
613 5 0 if $sense != 0
633 12 0 if ($hints->{'target_type'} eq 'channel')
676 2 2 defined $args{'target'} ? :
2 4 ref $args{'targets'} eq 'ARRAY' ? :