Branch Coverage

blib/lib/Net/Facebook/Oauth2.pm
Criterion Covered Total %
branch 24 76 31.5


line true false branch
18 0 7 defined $options{'api_version'} ? :
20 3 4 unless (defined $options{'access_token'})
21 1 2 unless defined $self->{'options'}{'application_id'}
22 1 1 unless defined $self->{'options'}{'application_secret'}
25 0 5 if (defined $options{'access_token_url'}) { }
26 0 0 if defined $options{'api_version'}
33 0 5 if (defined $options{'authorize_url'}) { }
34 0 0 if defined $options{'api_version'}
41 0 5 if (defined $options{'debug_token_url'}) { }
42 0 0 if defined $options{'api_version'}
60 0 0 unless defined $params{'callback'}
62 0 0 unless defined $params{'display'}
71 0 0 if ($params{'scope'})
73 0 0 if $scope
76 0 0 defined $params{'state'} ? :
78 0 0 if $params{'response_type'}
79 0 0 if $params{'auth_type'}
91 0 0 unless defined $params{'code'}
92 0 0 unless defined $params{'callback'}
108 0 0 if (not $response->is_success or exists $json->{'error'}) { }
0 0 elsif ($json->{'access_token'}) { }
124 0 0 unless ($self->{'access_token'})
125 0 0 unless defined $params{'access_token'}
136 0 0 if (not $response->is_success or exists $json->{'error'}) { }
0 0 elsif ($json->{'access_token'}) { }
150 0 0 unless defined $params{'input'}
165 0 0 if (not $response->is_success or exists $json->{'error'}) { }
0 0 elsif (not exists $json->{'data'}{'app_id'} && exists $json->{'data'}{'user_id'}) { }
0 0 elsif (not $params{'skip_check'} and '' . $json->{'data'}{'app_id'} ne '' . $self->{'options'}{'application_id'}) { }
181 5 2 unless ($self->_has_access_token($url))
182 0 5 unless defined $self->{'access_token'}
183 1 4 $self->{'_has_query'} ? :
196 5 2 if $string
205 1 1 unless ($self->_has_access_token($url))
206 0 1 unless defined $self->{'access_token'}
216 1 0 unless ($self->_has_access_token($url))
217 0 1 unless defined $self->{'access_token'}
247 3 7 if (grep {$_ eq 'access_token';} keys %q)