OAuth/Lite2/Agent/Dump.pm

filter: Statementstmt 72.2% 13 / 18 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 80.0% 4 / 5 Podpod 100% 1 / 1 totaltotal 75.0% 18 / 24 CC 1 SCAR 1.8
CC
1
Cov
72%
request
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« OAuth/Lite2/Formatter/Text.pm ↑ Summary OAuth/Lite2/Agent/PSGIMock.pm »
1 package OAuth::Lite2::Agent::Dump;
2  
3 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 1 ▶use parent 'OAuth::Lite2::Agent';
Subroutine BEGIN: called CC=1 SCAR=0.0
7 1 ▶use Data::Dump qw(dump);
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 =head1 NAME
10  
11 OAuth::Lite2::Agent::Dump - Preset User Agent class for debug
12  
13 =head1 SYNOPSIS
14  
15 my $client = OAuth::Lite2::Client::WebApp->new(
16 ..., # other params
17 agent => OAuth::Lite2::Client::Agent::Dump->new,
18 );
19  
20 =head1 DESCRIPTION
21  
22 This is useful for debug.
23  
24 =head1 METHODS
25  
26 =head2 request ($req)
27  
28 Append to the behavior of parent class, this method dumps the request and response object.
29  
30 =cut
31  
32 0 ▶sub request {
Subroutine request: not called CC=1 SCAR=6.9
Pod documented
33 0 my ($self, $req) = @_;
34 0 warn dump($req);
35 0 my $res = $self->SUPER::request($req);
36 0 warn dump($res);
37 0 return $res;
38 }
39  
40 1 1;
41  
42 =head1 SEE ALSO
43  
44 L<OAuth::Lite2::Client::Agent>,
45 L<OAuth::Lite2::Client::Agent::Strict>
46  
47 =head1 AUTHOR
48  
49 Lyo Kato, C<lyo.kato _at_ gmail.com>
50  
51 =head1 COPYRIGHT AND LICENSE
52  
53 This library is free software; you can redistribute it and/or modify
54 it under the same terms as Perl itself, either Perl version 5.8.8 or,
55 at your option, any later version of Perl 5 you may have available.
56  
57 =cut
« OAuth/Lite2/Formatter/Text.pm ↑ Summary OAuth/Lite2/Agent/PSGIMock.pm »