Branch Coverage

blib/lib/Mojo/WebSocketProxy/Dispatcher.pm
Criterion Covered Total %
branch 23 32 71.8


line true false branch
58 0 23 if $config->{'stream_timeout'}
59 0 23 if $config->{'max_connections'}
61 0 23 if $config->{'opened_connection'}
69 33 1 if (my $args = eval { do { decode_json_utf8($normalized_msg) } }) { }
80 1 0 if $bytes and exists $config->{'binary_frame'}
83 0 23 if $config->{'finish_connection'}
97 0 33 if (my $err = Mojo::WebSocketProxy::Parser::parse_req($c, $req_storage))
102 2 31 unless (my $action = $c->dispatch($args))
115 2 21 if $req_storage->{'instead_of_forward'}
138 8 23 if $result
152 7 55 ref $_->{'before_forward'} eq 'ARRAY' ? :
175 10 9 unless my $result = &$hook($c, @hook_params)
176 4 5 if &blessed($result) and $result->isa('Future')
206 0 69 ref $config->{$hook} eq 'ARRAY' ? :
0 69 ref $req_storage->{$hook} eq 'ARRAY' ? :
211 0 23 unless my $backend = $c->wsp_config->{'backends'}{$backend_name}