Branch Coverage

blib/lib/Mojo/IOLoop.pm
Criterion Covered Total %
branch 40 44 90.9


line true false branch
35 190 179 unless ref $acceptor
77 1 1380 if $self->is_running
86 325 204 if ($c and my $stream = $c->{'stream'})
94 1 3 if ($options->{'freeze'}) { }
115 1 234 if (my $max = $self->max_accepts)
117 1 0 if ($self->{'accepts'} -= 1) <= 0
121 3 232 if $self->_limit
133 3 1074 if $self->is_running
141 1 2 if ++$self->{'stop'} and not $self->emit("finish")->_in
146 1 7631 if ref $stream
153 0 0 @_ ? :
167 17043 943 ref $_[0] ? :
169 3 552 $_[0]{'stop'} ? :
173 397 318 if $self->{'accepting'} or $self->_limit
180 80 243 unless delete $self->{'accepting'}
191 0 604 unless my $reactor = $self->reactor
192 26 578 if $reactor->remove($id)
195 138 440 if delete $self->{'acceptors'}{$id}
198 40 201 unless delete $self->{'in'}{$id} or delete $self->{'out'}{$id}
199 2 398 if $self->{'stop'} and not $self->_in
208 235 234 $server ? :
211 397 4 if $self